浏览代码

remove ui.js and update build process

Konstantinos Kaloutas 1 年之前
父节点
当前提交
8fd90fa90a
共有 5 个文件被更改,包括 6 次插入14 次删除
  1. 1 0
      gulpfile.js
  2. 2 1
      package.json
  3. 3 3
      packages/ui/package.json
  4. 0 0
      packages/ui/src/ui.ts
  5. 0 10
      resources/js/ui.js

+ 1 - 0
gulpfile.js

@@ -65,6 +65,7 @@ const common = {
         'node_modules/@highlightjs/cdn-assets/highlight.min.js',
         'node_modules/@isomorphic-git/lightning-fs/dist/lightning-fs.min.js',
         'packages/amplify/dist/amplify.js',
+        'packages/ui/dist/ui.js',
         'node_modules/@logseq/sqlite-wasm/sqlite-wasm/jswasm/sqlite3.wasm',
       ]).pipe(gulp.dest(path.join(outputPath, 'js'))),
       () => gulp.src([

+ 2 - 1
package.json

@@ -76,7 +76,8 @@
         "android:dev": "cross-env PLATFORM=android gulp cap",
         "tldraw:build": "yarn --cwd packages/tldraw install",
         "amplify:build": "yarn --cwd packages/amplify install",
-        "postinstall": "yarn tldraw:build && yarn amplify:build "
+        "ui:build": "yarn --cwd packages/ui install",
+        "postinstall": "yarn tldraw:build && yarn amplify:build && yarn ui:build"
     },
     "dependencies": {
         "@capacitor/android": "^5.0.0",

+ 3 - 3
packages/ui/package.json

@@ -6,9 +6,9 @@
   "scripts": {
     "watch:ui:examples": "parcel serve ./examples/index.html",
     "build:ui:only": "parcel build --target ui --no-source-maps",
-    "build:ui": "rm -rf .parcel-cache && yarn build:ui:only && cp dist/index.js ../../resources/js/ui.js",
+    "build:ui": "rm -rf .parcel-cache && yarn build:ui:only",
     "watch:storybook": "storybook dev -p 6006",
-    "_postinstall": "yarn build:ui"
+    "postinstall": "yarn build:ui"
   },
   "dependencies": {
     "@hookform/resolvers": "^3.3.2",
@@ -84,7 +84,7 @@
   "targets": {
     "main": false,
     "ui": {
-      "source": "src/index.ts",
+      "source": "src/ui.ts",
       "outputFormat": "global",
       "includeNodeModules": {
         "react": false,

+ 0 - 0
packages/ui/src/index.ts → packages/ui/src/ui.ts


文件差异内容过多而无法显示
+ 0 - 10
resources/js/ui.js


部分文件因为文件数量过多而无法显示