@modern-js/server-utils 1.2.5 → 1.2.6

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/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @modern-js/server-utils
2
2
 
3
+ ## 1.2.6
4
+
5
+ ### Patch Changes
6
+
7
+ - d32f35134: chore: add modern/jest/eslint/ts config files to .npmignore
8
+ - 1a30be07b: fix: remove some babel plugins that provided by @babel/preset-env
9
+ - Updated dependencies [f1ca8eb83]
10
+ - Updated dependencies [d5913bd96]
11
+ - Updated dependencies [d32f35134]
12
+ - Updated dependencies [6ae4a34ae]
13
+ - Updated dependencies [b80229c79]
14
+ - Updated dependencies [948cc4436]
15
+ - @modern-js/babel-preset-lib@1.2.5
16
+ - @modern-js/plugin@1.3.4
17
+ - @modern-js/utils@1.7.3
18
+
3
19
  ## 1.2.5
4
20
 
5
21
  ### Patch Changes
@@ -71,9 +71,6 @@ export const resolveBabelConfig = (appDirectory, modernConfig, option // FIXME:
71
71
  babelChain.plugin('@babel/plugin-proposal-decorators').use(require.resolve('@babel/plugin-proposal-decorators'), [{
72
72
  legacy: true
73
73
  }]);
74
- babelChain.plugin('@babel/plugin-proposal-class-properties').use(require.resolve('@babel/plugin-proposal-class-properties'), [{
75
- loose: true
76
- }]);
77
74
 
78
75
  const internalBabelConfig = _objectSpread({}, babelChain.toJSON());
79
76
 
@@ -109,9 +109,6 @@ const resolveBabelConfig = (appDirectory, modernConfig, option // FIXME: babel t
109
109
  babelChain.plugin('@babel/plugin-proposal-decorators').use(require.resolve('@babel/plugin-proposal-decorators'), [{
110
110
  legacy: true
111
111
  }]);
112
- babelChain.plugin('@babel/plugin-proposal-class-properties').use(require.resolve('@babel/plugin-proposal-class-properties'), [{
113
- loose: true
114
- }]);
115
112
 
116
113
  const internalBabelConfig = _objectSpread({}, babelChain.toJSON());
117
114
 
@@ -1,9 +1,4 @@
1
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
2
-
3
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
-
5
- function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
-
1
+ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
7
2
  import { getBabelChain } from '@modern-js/babel-preset-lib';
8
3
  import { fs, json5, getAlias, applyOptionsChain } from '@modern-js/utils';
9
4
  export * from '@babel/core';
@@ -67,9 +62,6 @@ export var resolveBabelConfig = function resolveBabelConfig(appDirectory, modern
67
62
  babelChain.plugin('@babel/plugin-proposal-decorators').use(require.resolve('@babel/plugin-proposal-decorators'), [{
68
63
  legacy: true
69
64
  }]);
70
- babelChain.plugin('@babel/plugin-proposal-class-properties').use(require.resolve('@babel/plugin-proposal-class-properties'), [{
71
- loose: true
72
- }]);
73
65
 
74
66
  var internalBabelConfig = _objectSpread({}, babelChain.toJSON());
75
67
 
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "modern",
12
12
  "modern.js"
13
13
  ],
14
- "version": "1.2.5",
14
+ "version": "1.2.6",
15
15
  "jsnext:source": "./src/index.ts",
16
16
  "types": "./dist/types/index.d.ts",
17
17
  "main": "./dist/js/node/index.js",
@@ -30,21 +30,20 @@
30
30
  "dependencies": {
31
31
  "@babel/compat-data": "^7.15.0",
32
32
  "@babel/core": "^7.17.0",
33
- "@babel/plugin-proposal-class-properties": "^7.14.5",
34
33
  "@babel/plugin-proposal-decorators": "^7.15.4",
35
- "@babel/preset-env": "^7.15.0",
34
+ "@babel/preset-env": "^7.17.0",
36
35
  "@babel/preset-typescript": "^7.15.0",
37
36
  "@babel/runtime": "^7",
38
- "@modern-js/babel-preset-lib": "^1.2.4",
39
- "@modern-js/plugin": "^1.3.3",
40
- "@modern-js/utils": "^1.7.2",
37
+ "@modern-js/babel-preset-lib": "^1.2.5",
38
+ "@modern-js/plugin": "^1.3.4",
39
+ "@modern-js/utils": "^1.7.3",
41
40
  "babel-plugin-module-resolver": "^4.1.0",
42
41
  "babel-plugin-transform-typescript-metadata": "^0.3.2"
43
42
  },
44
43
  "devDependencies": {
45
- "@modern-js/core": "1.10.1",
44
+ "@modern-js/core": "1.10.2",
46
45
  "@types/babel__core": "^7.1.15",
47
- "@types/jest": "^26",
46
+ "@types/jest": "^27",
48
47
  "@types/node": "^14",
49
48
  "@types/react": "^17",
50
49
  "@types/react-dom": "^17",
@@ -59,10 +58,32 @@
59
58
  "registry": "https://registry.npmjs.org/",
60
59
  "access": "public"
61
60
  },
61
+ "wireit": {
62
+ "build": {
63
+ "command": "modern build",
64
+ "files": [
65
+ "src/**/*",
66
+ "tsconfig.json",
67
+ "package.json"
68
+ ],
69
+ "output": [
70
+ "dist/**/*"
71
+ ]
72
+ },
73
+ "test": {
74
+ "command": "jest --passWithNoTests",
75
+ "files": [
76
+ "src/**/*",
77
+ "tsconfig.json",
78
+ "package.json"
79
+ ],
80
+ "output": []
81
+ }
82
+ },
62
83
  "scripts": {
63
84
  "new": "modern new",
64
- "build": "modern build",
65
- "test": "jest --passWithNoTests"
85
+ "build": "wireit",
86
+ "test": "wireit"
66
87
  },
67
88
  "readme": "\n<p align=\"center\">\n <a href=\"https://modernjs.dev\" target=\"blank\"><img src=\"https://lf3-static.bytednsdoc.com/obj/eden-cn/ylaelkeh7nuhfnuhf/modernjs-cover.png\" width=\"300\" alt=\"Modern.js Logo\" /></a>\n</p>\n<p align=\"center\">\n现代 Web 工程体系\n <br/>\n <a href=\"https://modernjs.dev\" target=\"blank\">\n modernjs.dev\n </a>\n</p>\n<p align=\"center\">\n The meta-framework suite designed from scratch for frontend-focused modern web development\n</p>\n\n# Introduction\n\n> The doc site ([modernjs.dev](https://modernjs.dev)) and articles are only available in Chinese for now, we are planning to add English versions soon.\n\n- [Modern.js: Hello, World!](https://zhuanlan.zhihu.com/p/426707646)\n\n## Getting Started\n\n- [Quick Start](https://modernjs.dev/docs/start)\n- [Guides](https://modernjs.dev/docs/guides)\n- [API References](https://modernjs.dev/docs/apis)\n\n## Contributing\n\n- [Contributing Guide](https://github.com/modern-js-dev/modern.js/blob/main/CONTRIBUTING.md)\n"
68
89
  }
package/.eslintrc.js DELETED
@@ -1,8 +0,0 @@
1
- module.exports = {
2
- root: true,
3
- extends: ['@modern-js'],
4
- parserOptions: {
5
- tsconfigRootDir: __dirname,
6
- project: ['./tsconfig.json'],
7
- },
8
- };
package/jest.config.js DELETED
@@ -1,7 +0,0 @@
1
- const sharedConfig = require('@scripts/jest-config');
2
-
3
- /** @type {import('@jest/types').Config.InitialOptions} */
4
- module.exports = {
5
- ...sharedConfig,
6
- rootDir: __dirname,
7
- };
package/modern.config.js DELETED
@@ -1,2 +0,0 @@
1
- /** @type {import('@modern-js/module-tools').UserConfig} */
2
- module.exports = {};
package/tsconfig.json DELETED
@@ -1,12 +0,0 @@
1
- {
2
- "extends": "@modern-js/tsconfig/base",
3
- "compilerOptions": {
4
- "declaration": false,
5
- "jsx": "preserve",
6
- "baseUrl": "./",
7
- "isolatedModules": true,
8
- "paths": {},
9
- "types": ["node", "jest"]
10
- },
11
- "include": ["src"]
12
- }