@nextelco/common-ui 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,5 @@
1
+ 'use strict';
2
+
3
+ require('react');
4
+
5
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
@@ -0,0 +1,2 @@
1
+ import 'react';
2
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const Button: () => React.JSX.Element;
3
+ export default Button;
@@ -0,0 +1 @@
1
+ export * from './components/Button';
package/package.json ADDED
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "@nextelco/common-ui",
3
+ "type": "module",
4
+ "version": "1.0.2",
5
+ "main": "dist/index.cjs.js",
6
+ "module": "dist/index.esm.js",
7
+ "types": "dist/types/index.d.ts",
8
+ "scripts": {
9
+ "build": "rollup -c",
10
+ "prepare": "npm run build",
11
+ "test": "echo \"Write tests!\"",
12
+ "pub": " npm version patch && npm run build && npm publish --access public"
13
+ },
14
+ "keywords": [
15
+ "react",
16
+ "library",
17
+ "typescript"
18
+ ],
19
+ "peerDependencies": {
20
+ "react": "^17.0.0 || ^18.0.0",
21
+ "react-dom": "^17.0.0 || ^18.0.0"
22
+ },
23
+ "devDependencies": {
24
+ "typescript": "^4.0.0",
25
+ "@rollup/plugin-typescript": "^8.0.0",
26
+ "rollup": "^2.0.0",
27
+ "tslib": "^2.0.0"
28
+ }
29
+ }
@@ -0,0 +1,19 @@
1
+ import typescript from '@rollup/plugin-typescript'
2
+
3
+ export default {
4
+ input: 'src/index.ts', // Your entry point
5
+ output: [
6
+ {
7
+ file: 'dist/index.cjs.js',
8
+ format: 'cjs',
9
+ sourcemap: true,
10
+ },
11
+ {
12
+ file: 'dist/index.esm.js',
13
+ format: 'esm',
14
+ sourcemap: true,
15
+ },
16
+ ],
17
+ plugins: [typescript()],
18
+ external: ['react', 'react-dom'], // Treat React as external to avoid bundling
19
+ }
@@ -0,0 +1,7 @@
1
+ import React from 'react'
2
+
3
+ const Button = () => {
4
+ return <div>Button</div>
5
+ }
6
+
7
+ export default Button
package/src/index.ts ADDED
@@ -0,0 +1 @@
1
+ export * from './components/Button'
package/tsconfig.json ADDED
@@ -0,0 +1,15 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES5",
4
+ "lib": ["dom", "esnext"],
5
+ "jsx": "react",
6
+ "declaration": true,
7
+ "declarationDir": "./dist/types",
8
+ "module": "ESNext",
9
+ "moduleResolution": "node",
10
+ "esModuleInterop": true,
11
+ "skipLibCheck": true,
12
+ "strict": true
13
+ },
14
+ "include": ["src/**/*"]
15
+ }