From 2e9a3426524a54c6a743600572f8f08bc0a02061 Mon Sep 17 00:00:00 2001 From: Evan You Date: Wed, 19 Sep 2018 22:25:55 -0400 Subject: [PATCH] build: simplify compiler package setup --- packages/compiler-core/README.md | 1 - packages/compiler-core/index.js | 7 ------- packages/compiler-core/package.json | 21 ------------------- packages/compiler-dom/.npmignore | 3 --- packages/compiler-dom/README.md | 1 - packages/compiler-dom/index.js | 7 ------- packages/compiler-dom/src/index.ts | 0 packages/compiler-server/.npmignore | 3 --- packages/compiler-server/README.md | 1 - packages/compiler-server/index.js | 7 ------- packages/compiler-server/package.json | 21 ------------------- packages/compiler-server/src/index.ts | 0 .../{compiler-core => compiler}/.npmignore | 0 packages/compiler/README.md | 1 + packages/compiler/index.js | 7 +++++++ .../{compiler-dom => compiler}/package.json | 10 ++++----- .../{compiler-core => compiler}/src/index.ts | 0 .../observer/__tests__/collections.spec.ts | 4 +++- tsconfig.json | 4 +--- 19 files changed, 17 insertions(+), 81 deletions(-) delete mode 100644 packages/compiler-core/README.md delete mode 100644 packages/compiler-core/index.js delete mode 100644 packages/compiler-core/package.json delete mode 100644 packages/compiler-dom/.npmignore delete mode 100644 packages/compiler-dom/README.md delete mode 100644 packages/compiler-dom/index.js delete mode 100644 packages/compiler-dom/src/index.ts delete mode 100644 packages/compiler-server/.npmignore delete mode 100644 packages/compiler-server/README.md delete mode 100644 packages/compiler-server/index.js delete mode 100644 packages/compiler-server/package.json delete mode 100644 packages/compiler-server/src/index.ts rename packages/{compiler-core => compiler}/.npmignore (100%) create mode 100644 packages/compiler/README.md create mode 100644 packages/compiler/index.js rename packages/{compiler-dom => compiler}/package.json (73%) rename packages/{compiler-core => compiler}/src/index.ts (100%) diff --git a/packages/compiler-core/README.md b/packages/compiler-core/README.md deleted file mode 100644 index 33a82ccf..00000000 --- a/packages/compiler-core/README.md +++ /dev/null @@ -1 +0,0 @@ -# @vue/compiler-core \ No newline at end of file diff --git a/packages/compiler-core/index.js b/packages/compiler-core/index.js deleted file mode 100644 index d3fc54f4..00000000 --- a/packages/compiler-core/index.js +++ /dev/null @@ -1,7 +0,0 @@ -'use strict' - -if (process.env.NODE_ENV === 'production') { - module.exports = require('./dist/compiler-core.cjs.prod.js') -} else { - module.exports = require('./dist/compiler-core.cjs.js') -} diff --git a/packages/compiler-core/package.json b/packages/compiler-core/package.json deleted file mode 100644 index 7d500b33..00000000 --- a/packages/compiler-core/package.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "@vue/compiler-core", - "version": "3.0.0-alpha.1", - "description": "@vue/compiler-core", - "main": "index.js", - "module": "dist/compiler-core.esm-bundler.js", - "typings": "dist/index.d.ts", - "repository": { - "type": "git", - "url": "git+https://github.com/vuejs/vue.git" - }, - "keywords": [ - "vue" - ], - "author": "Evan You", - "license": "MIT", - "bugs": { - "url": "https://github.com/vuejs/vue/issues" - }, - "homepage": "https://github.com/vuejs/vue/tree/dev/packages/compiler-core#readme" -} diff --git a/packages/compiler-dom/.npmignore b/packages/compiler-dom/.npmignore deleted file mode 100644 index bb5c8a54..00000000 --- a/packages/compiler-dom/.npmignore +++ /dev/null @@ -1,3 +0,0 @@ -__tests__/ -__mocks__/ -dist/packages \ No newline at end of file diff --git a/packages/compiler-dom/README.md b/packages/compiler-dom/README.md deleted file mode 100644 index 0027f542..00000000 --- a/packages/compiler-dom/README.md +++ /dev/null @@ -1 +0,0 @@ -# @vue/compiler-dom \ No newline at end of file diff --git a/packages/compiler-dom/index.js b/packages/compiler-dom/index.js deleted file mode 100644 index b5f7a05e..00000000 --- a/packages/compiler-dom/index.js +++ /dev/null @@ -1,7 +0,0 @@ -'use strict' - -if (process.env.NODE_ENV === 'production') { - module.exports = require('./dist/compiler-dom.cjs.prod.js') -} else { - module.exports = require('./dist/compiler-dom.cjs.js') -} diff --git a/packages/compiler-dom/src/index.ts b/packages/compiler-dom/src/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/compiler-server/.npmignore b/packages/compiler-server/.npmignore deleted file mode 100644 index bb5c8a54..00000000 --- a/packages/compiler-server/.npmignore +++ /dev/null @@ -1,3 +0,0 @@ -__tests__/ -__mocks__/ -dist/packages \ No newline at end of file diff --git a/packages/compiler-server/README.md b/packages/compiler-server/README.md deleted file mode 100644 index 24d04239..00000000 --- a/packages/compiler-server/README.md +++ /dev/null @@ -1 +0,0 @@ -# @vue/compiler-server \ No newline at end of file diff --git a/packages/compiler-server/index.js b/packages/compiler-server/index.js deleted file mode 100644 index 31c34293..00000000 --- a/packages/compiler-server/index.js +++ /dev/null @@ -1,7 +0,0 @@ -'use strict' - -if (process.env.NODE_ENV === 'production') { - module.exports = require('./dist/compiler-server.cjs.prod.js') -} else { - module.exports = require('./dist/compiler-server.cjs.js') -} diff --git a/packages/compiler-server/package.json b/packages/compiler-server/package.json deleted file mode 100644 index 1e508dd7..00000000 --- a/packages/compiler-server/package.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "name": "@vue/compiler-server", - "version": "3.0.0-alpha.1", - "description": "@vue/compiler-server", - "main": "index.js", - "module": "dist/compiler-server.esm-bundler.js", - "typings": "dist/index.d.ts", - "repository": { - "type": "git", - "url": "git+https://github.com/vuejs/vue.git" - }, - "keywords": [ - "vue" - ], - "author": "Evan You", - "license": "MIT", - "bugs": { - "url": "https://github.com/vuejs/vue/issues" - }, - "homepage": "https://github.com/vuejs/vue/tree/dev/packages/compiler-server#readme" -} diff --git a/packages/compiler-server/src/index.ts b/packages/compiler-server/src/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/compiler-core/.npmignore b/packages/compiler/.npmignore similarity index 100% rename from packages/compiler-core/.npmignore rename to packages/compiler/.npmignore diff --git a/packages/compiler/README.md b/packages/compiler/README.md new file mode 100644 index 00000000..f5a8b4f3 --- /dev/null +++ b/packages/compiler/README.md @@ -0,0 +1 @@ +# @vue/compiler \ No newline at end of file diff --git a/packages/compiler/index.js b/packages/compiler/index.js new file mode 100644 index 00000000..388d86ef --- /dev/null +++ b/packages/compiler/index.js @@ -0,0 +1,7 @@ +'use strict' + +if (process.env.NODE_ENV === 'production') { + module.exports = require('./dist/compiler.cjs.prod.js') +} else { + module.exports = require('./dist/compiler.cjs.js') +} diff --git a/packages/compiler-dom/package.json b/packages/compiler/package.json similarity index 73% rename from packages/compiler-dom/package.json rename to packages/compiler/package.json index d04e769f..edd6837a 100644 --- a/packages/compiler-dom/package.json +++ b/packages/compiler/package.json @@ -1,9 +1,9 @@ { - "name": "@vue/compiler-dom", + "name": "@vue/compiler", "version": "3.0.0-alpha.1", - "description": "@vue/compiler-dom", + "description": "@vue/compiler", "main": "index.js", - "module": "dist/compiler-dom.esm-bundler.js", + "module": "dist/compiler.esm-bundler.js", "typings": "dist/index.d.ts", "repository": { "type": "git", @@ -17,5 +17,5 @@ "bugs": { "url": "https://github.com/vuejs/vue/issues" }, - "homepage": "https://github.com/vuejs/vue/tree/dev/packages/compiler-dom#readme" -} + "homepage": "https://github.com/vuejs/vue/tree/dev/packages/compiler#readme" +} \ No newline at end of file diff --git a/packages/compiler-core/src/index.ts b/packages/compiler/src/index.ts similarity index 100% rename from packages/compiler-core/src/index.ts rename to packages/compiler/src/index.ts diff --git a/packages/observer/__tests__/collections.spec.ts b/packages/observer/__tests__/collections.spec.ts index da242d71..bb99db93 100644 --- a/packages/observer/__tests__/collections.spec.ts +++ b/packages/observer/__tests__/collections.spec.ts @@ -1 +1,3 @@ -describe('observer/collections', () => {}) +describe('observer/collections', () => { + describe('Map', () => {}) +}) diff --git a/tsconfig.json b/tsconfig.json index 3a203397..59fbad3f 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -24,9 +24,7 @@ "@vue/scheduler": ["packages/scheduler/src"], "@vue/renderer-dom": ["packages/renderer-dom/src"], "@vue/renderer-server": ["packages/renderer-server/src"], - "@vue/compiler-core": ["packages/compiler-core/src"], - "@vue/compiler-dom": ["packages/compiler-dom/src"], - "@vue/compiler-server": ["packages/compiler-server/src"] + "@vue/compiler": ["packages/compiler-core/src"] } }, "include": [