@agility/plenum-ui 2.0.0-rc18 → 2.0.0-rc19

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.
package/README.md CHANGED
@@ -75,6 +75,14 @@ npm run build
75
75
  yarn build
76
76
  ```
77
77
 
78
+ ### Build your project locally and watch for changes
79
+ This will create symlinks for the current project and its necessary dependencies, so that it can be connected to other projects.
80
+ It will also start the watch server, so it will automatically rebuild on any local changes.
81
+
82
+ ```
83
+ yarn start:local
84
+ ```
85
+
78
86
  #### Use yarn link to locally test the library in another project:
79
87
 
80
88
  In the Plenum project directory after having run a build, run:
package/build.js CHANGED
@@ -12,34 +12,35 @@ new Generator({
12
12
  // Run TypeScript to generate type declarations using the new tsconfig.lib.json
13
13
  execSync("tsc --emitDeclarationOnly --project tsconfig.lib.json", { stdio: "inherit" })
14
14
 
15
- // Build script using esbuild
16
- esbuild
17
- .build({
18
- logLevel: "info",
19
- entryPoints: [path.resolve(__dirname, "stories/index.ts")],
15
+ const context = {
16
+ logLevel: "info",
17
+ entryPoints: [path.resolve(__dirname, "stories/index.ts")],
20
18
 
21
- bundle: true,
22
- platform: "browser",
23
- target: ["esnext"],
24
- minify: true,
25
- pure: ["React.createElement"],
26
- jsx: 'transform',
27
- loader: { '.js': 'jsx' },
19
+ bundle: true,
20
+ platform: "browser",
21
+ target: ["esnext"],
22
+ minify: true,
23
+ pure: ["React.createElement"],
24
+ jsx: 'transform',
25
+ loader: { '.js': 'jsx' },
26
+ outdir: path.resolve(__dirname, "dist"),
27
+ sourcemap: true,
28
+ external: [
29
+ "react",
30
+ "react-dom",
31
+ "@floating-ui/react",
32
+ "@headlessui/react",
33
+ "@headlessui/tailwindcss",
34
+ "@heroicons/react",
35
+ "@tabler/icons",
36
+ "@tabler/icons-react",
37
+ "classnames",
38
+ "react-icons"
39
+ ],
40
+ format: "esm"
41
+ }
28
42
 
29
- outdir: path.resolve(__dirname, "dist"),
30
- sourcemap: true,
31
- external: [
32
- "react",
33
- "react-dom",
34
- "@floating-ui/react",
35
- "@headlessui/react",
36
- "@headlessui/tailwindcss",
37
- "@heroicons/react",
38
- "@tabler/icons",
39
- "@tabler/icons-react",
40
- "classnames",
41
- "react-icons"
42
- ],
43
- format: "esm"
44
- })
45
- .catch(() => process.exit(1))
43
+ // Build script using esbuild
44
+ esbuild
45
+ .build(context)
46
+ .catch(() => process.exit(1))