balm-core 3.22.0 → 3.23.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.
Files changed (54) hide show
  1. package/README.md +9 -16
  2. package/lib/config/globals.js +1 -1
  3. package/lib/utilities/loading.js +3 -1
  4. package/package.json +16 -16
  5. package/tslib/balm.js +6 -6
  6. package/tslib/bootstrap/index.js +1 -1
  7. package/tslib/bundler/esbuild/index.js +2 -2
  8. package/tslib/bundler/esbuild/transform.js +2 -2
  9. package/tslib/bundler/rollup/index.js +4 -4
  10. package/tslib/bundler/webpack/config/common.js +1 -1
  11. package/tslib/bundler/webpack/config/dev.js +2 -2
  12. package/tslib/bundler/webpack/config/index.js +2 -2
  13. package/tslib/bundler/webpack/config/prod.js +2 -2
  14. package/tslib/bundler/webpack/index.js +4 -4
  15. package/tslib/bundler/webpack/loaders.js +2 -2
  16. package/tslib/config/globals.js +4 -4
  17. package/tslib/config/index.js +13 -13
  18. package/tslib/config/version.js +1 -1
  19. package/tslib/hello.js +1 -1
  20. package/tslib/hooks/index.js +1 -1
  21. package/tslib/index.js +2 -2
  22. package/tslib/middlewares/index.js +3 -3
  23. package/tslib/plugins/imagemin.js +1 -1
  24. package/tslib/plugins/index.js +11 -11
  25. package/tslib/plugins/less.js +3 -3
  26. package/tslib/plugins/postcss.js +1 -1
  27. package/tslib/plugins/replace.js +1 -1
  28. package/tslib/plugins/sass.js +2 -2
  29. package/tslib/plugins/sftp.js +1 -1
  30. package/tslib/tasks/foundation/balm_style.js +1 -1
  31. package/tslib/tasks/foundation/index.js +2 -2
  32. package/tslib/tasks/index.js +3 -3
  33. package/tslib/tasks/private/clean.js +2 -2
  34. package/tslib/tasks/private/modernizr.js +4 -4
  35. package/tslib/tasks/private/sprite.js +4 -4
  36. package/tslib/tasks/public/esbuild.js +1 -1
  37. package/tslib/tasks/public/html.js +5 -5
  38. package/tslib/tasks/public/publish.js +3 -3
  39. package/tslib/tasks/public/remove.js +1 -1
  40. package/tslib/tasks/public/rollup.js +1 -1
  41. package/tslib/tasks/public/server.js +9 -9
  42. package/tslib/tasks/public/url.js +2 -2
  43. package/tslib/tasks/public/webpack.js +1 -1
  44. package/tslib/utilities/address.js +1 -1
  45. package/tslib/utilities/cache-core.js +3 -3
  46. package/tslib/utilities/color.js +1 -1
  47. package/tslib/utilities/compiling.js +4 -4
  48. package/tslib/utilities/detect-port.js +2 -2
  49. package/tslib/utilities/file.js +2 -2
  50. package/tslib/utilities/index.js +4 -4
  51. package/tslib/utilities/loading.js +8 -8
  52. package/tslib/utilities/logger.js +8 -8
  53. package/tslib/utilities/replacestream.js +1 -1
  54. package/tslib/utilities/utils.js +1 -1
package/README.md CHANGED
@@ -5,17 +5,16 @@
5
5
  <br>
6
6
  <br>
7
7
 
8
- [![NPM version][balm-image]][balm-url]
8
+ [![NPM version][balm-core-image]][balm-core-url]
9
9
  [![License][license-image]][license-url]
10
- [![Dependency Status][deps-image]][deps-url]
11
- [![Build Status][travis-image]][travis-url]
12
- [![Build Status][appveyor-image]][appveyor-url]
13
10
  [![Coverage Percentage][cover-image]][cover-url]
14
11
 
15
12
  <h1>BalmJS</h1>
16
13
  <p>An universal Front-End workflow for webapps</p>
17
14
  </div>
18
15
 
16
+ > :tada: [`balm-core@next`](https://github.com/balmjs/balm/tree/main)(v4) supports for `node@12+`, `sass@latest`, `postcss@8`, `webpack@5`
17
+
19
18
  ## Introduction
20
19
 
21
20
  BalmJS prescribes best practices and tools to help you stay productive.
@@ -173,25 +172,19 @@ We'd love for you to contribute and make BalmJS even better than it is today! Pl
173
172
 
174
173
  © 2016-present, [Elf-mousE](http://elf-mouse.me/)
175
174
 
176
- [balm-core-image]: https://badge.fury.io/js/balm-core.svg
175
+ [balm-core-image]: https://img.shields.io/npm/v/balm-core.svg
177
176
  [balm-core-url]: https://npmjs.org/package/balm-core
178
- [balm-image]: https://badge.fury.io/js/balm.svg
177
+ [balm-image]: https://img.shields.io/npm/v/balm.svg
179
178
  [balm-url]: https://npmjs.org/package/balm
180
179
  [license-image]: https://img.shields.io/npm/l/balm-core.svg?sanitize=true
181
180
  [license-url]: https://www.npmjs.com/package/balm-core
182
- [deps-image]: https://david-dm.org/balmjs/balm.svg?path=packages/balm-core&theme=shields.io
183
- [deps-url]: https://david-dm.org/balmjs/balm?path=packages/balm-core
184
- [travis-image]: https://travis-ci.com/balmjs/balm.svg?branch=master
185
- [travis-url]: https://travis-ci.com/balmjs/balm
186
- [appveyor-image]: https://ci.appveyor.com/api/projects/status/github/balmjs/balm?svg=true
187
- [appveyor-url]: https://ci.appveyor.com/project/balmjs/balm
188
181
  [cover-image]: https://coveralls.io/repos/balmjs/balm/badge.svg
189
182
  [cover-url]: https://coveralls.io/r/balmjs/balm
190
- [balm-cli-image]: https://badge.fury.io/js/balm-cli.svg
183
+ [balm-cli-image]: https://img.shields.io/npm/v/balm-cli.svg
191
184
  [balm-cli-url]: https://npmjs.org/package/balm-cli
192
- [balm-ui-lite-image]: https://badge.fury.io/js/balm-ui-lite.svg
185
+ [balm-ui-lite-image]: https://img.shields.io/npm/v/balm-ui-lite.svg
193
186
  [balm-ui-lite-url]: https://npmjs.org/package/balm-ui-lite
194
- [balm-ui-image]: https://badge.fury.io/js/balm-ui.svg
187
+ [balm-ui-image]: https://img.shields.io/npm/v/balm-ui.svg
195
188
  [balm-ui-url]: https://npmjs.org/package/balm-ui
196
- [balm-scroll-image]: https://badge.fury.io/js/balm-scroll.svg
189
+ [balm-scroll-image]: https://img.shields.io/npm/v/balm-scroll.svg
197
190
  [balm-scroll-url]: https://npmjs.org/package/balm-scroll
@@ -10,7 +10,7 @@ var _ansiColors = _interopRequireDefault(require("ansi-colors"));
10
10
 
11
11
  // Set env var for ORIGINAL cwd before anything touches it
12
12
  process.env.BALM_CWD = process.env.INIT_CWD || process.cwd();
13
- var gulpModule = "".concat(process.env.BALM || process.env.BALM_CWD, "/node_modules/gulp/index.js");
13
+ var gulpModule = "".concat(process.env.BALM_ROOT || process.env.BALM_CWD, "/node_modules/gulp/index.js");
14
14
 
15
15
  if (!_fs["default"].existsSync(gulpModule)) {
16
16
  console.error(_ansiColors["default"].bgBlueBright('BalmJS'), _ansiColors["default"].yellow('`balm` module not found :('));
@@ -54,9 +54,11 @@ var BalmLoading = /*#__PURE__*/function () {
54
54
  (0, _createClass2["default"])(BalmLoading, [{
55
55
  key: "frame",
56
56
  get: function get() {
57
+ var _this$frameIndex;
58
+
57
59
  var currentFrame = _spinner["default"].frames[(0, _classPrivateFieldGet2["default"])(this, _frameIndex)];
58
60
 
59
- (0, _classPrivateFieldSet2["default"])(this, _frameIndex, (0, _classPrivateFieldSet2["default"])(this, _frameIndex, +(0, _classPrivateFieldGet2["default"])(this, _frameIndex) + 1) % (0, _classPrivateFieldGet2["default"])(this, _frameCount));
61
+ (0, _classPrivateFieldSet2["default"])(this, _frameIndex, (0, _classPrivateFieldSet2["default"])(this, _frameIndex, (_this$frameIndex = (0, _classPrivateFieldGet2["default"])(this, _frameIndex), ++_this$frameIndex)) % (0, _classPrivateFieldGet2["default"])(this, _frameCount));
60
62
  return currentFrame;
61
63
  }
62
64
  }, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "balm-core",
3
- "version": "3.22.0",
3
+ "version": "3.23.2",
4
4
  "description": "BalmJS compiler core",
5
5
  "keywords": [
6
6
  "balm",
@@ -42,12 +42,12 @@
42
42
  "dependencies": {
43
43
  "ansi-colors": "^4.1.1",
44
44
  "async": "^3.2.3",
45
- "autoprefixer": "^10.4.2",
46
- "babel-loader": "^8.2.3",
47
- "browser-sync": "^2.27.7",
45
+ "autoprefixer": "9",
46
+ "babel-loader": "^8.2.5",
47
+ "browser-sync": "^2.27.9",
48
48
  "connect-history-api-fallback": "^1.6.0",
49
49
  "css-loader": "5",
50
- "cssnano": "^5.0.17",
50
+ "cssnano": "4",
51
51
  "del": "^6.0.0",
52
52
  "esbuild": "^0.14",
53
53
  "fancy-log": "^2.0.0",
@@ -69,31 +69,31 @@
69
69
  "istextorbinary": "^6.0.0",
70
70
  "less": "^4.1.2",
71
71
  "mini-css-extract-plugin": "1",
72
- "modernizr": "^3.11.8",
72
+ "modernizr": "^3.12.0",
73
73
  "optimize-css-assets-webpack-plugin": "^6.0.1",
74
74
  "parents": "^1.0.1",
75
75
  "plugin-error": "^1.0.1",
76
- "postcss": "^8.4.6",
77
- "postcss-import": "^14.0.2",
78
- "postcss-load-config": "^3.1.2",
76
+ "postcss": "7",
77
+ "postcss-import": "12",
78
+ "postcss-load-config": "2",
79
79
  "postcss-loader": "4",
80
80
  "postcss-preset-env": "6",
81
81
  "postcss-safe-parser": "5",
82
- "pretty-bytes": "^5.6.0",
82
+ "pretty-bytes": "5",
83
83
  "readable-stream": "^3.6.0",
84
84
  "replace-ext": "^2.0.0",
85
85
  "require-dir": "^1.2.0",
86
- "rollup": "^2.67.2",
86
+ "rollup": "^2.68.0",
87
87
  "rollup-plugin-terser": "^7.0.2",
88
88
  "sass": "1.39.2",
89
89
  "ssh2": "0.8.9",
90
90
  "strip-ansi": "6",
91
91
  "style-loader": "2",
92
- "terser": "^5.10.0",
92
+ "terser": "^5.13.1",
93
93
  "terser-webpack-plugin": "4",
94
94
  "through2": "^4.0.2",
95
95
  "through2-concurrent": "^2.0.0",
96
- "tslib": "^2.3.1",
96
+ "tslib": "^2.4.0",
97
97
  "url-loader": "^4.1.1",
98
98
  "vinyl-sourcemaps-apply": "^0.2.1",
99
99
  "webpack": "4",
@@ -101,11 +101,11 @@
101
101
  "webpack-dev-middleware": "3",
102
102
  "webpack-hot-middleware": "^2.25.1",
103
103
  "webpack-merge": "^5.8.0",
104
- "workbox-build": "^6.4.2"
104
+ "workbox-build": "^6.5.3"
105
105
  },
106
106
  "devDependencies": {
107
107
  "@types/express": "^4.17.13",
108
- "@types/node": "17.0.13",
108
+ "@types/node": "^17",
109
109
  "@types/webpack": "4"
110
110
  },
111
111
  "optionalDependencies": {
@@ -117,5 +117,5 @@
117
117
  "engines": {
118
118
  "node": ">=10.13.0"
119
119
  },
120
- "gitHead": "14c8b31a8a1a7d353c91a1d314a84e83028ae0f0"
120
+ "gitHead": "b411c85a2dac2c93648c22c7c662a90280246cd0"
121
121
  }
package/tslib/balm.js CHANGED
@@ -5,22 +5,22 @@ const tslib_1 = require("tslib");
5
5
  require("./config");
6
6
  require("./utilities");
7
7
  require("./plugins");
8
- const tasks_1 = (0, tslib_1.__importDefault)(require("./tasks"));
8
+ const tasks_1 = tslib_1.__importDefault(require("./tasks"));
9
9
  const bootstrap_1 = require("./bootstrap");
10
- const loading_1 = (0, tslib_1.__importDefault)(require("./utilities/loading"));
10
+ const loading_1 = tslib_1.__importDefault(require("./utilities/loading"));
11
11
  class Balm {
12
12
  constructor() {
13
13
  _Balm_config.set(this, void 0);
14
14
  BalmJS.loading = false;
15
15
  loading_1.default.succeed();
16
- (0, tslib_1.__classPrivateFieldSet)(this, _Balm_config, BalmJS.config, "f");
16
+ tslib_1.__classPrivateFieldSet(this, _Balm_config, BalmJS.config, "f");
17
17
  }
18
18
  get config() {
19
- return (0, tslib_1.__classPrivateFieldGet)(this, _Balm_config, "f");
19
+ return tslib_1.__classPrivateFieldGet(this, _Balm_config, "f");
20
20
  }
21
21
  set config(value) {
22
- (0, tslib_1.__classPrivateFieldSet)(this, _Balm_config, (0, bootstrap_1.setConfig)(value), "f");
23
- BalmJS.config = (0, tslib_1.__classPrivateFieldGet)(this, _Balm_config, "f");
22
+ tslib_1.__classPrivateFieldSet(this, _Balm_config, (0, bootstrap_1.setConfig)(value), "f");
23
+ BalmJS.config = tslib_1.__classPrivateFieldGet(this, _Balm_config, "f");
24
24
  }
25
25
  set beforeTask(name) {
26
26
  BalmJS.beforeTask = (0, bootstrap_1.setTask)(name);
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.setTask = exports.setConfig = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const check_config_1 = (0, tslib_1.__importDefault)(require("./check_config"));
5
+ const check_config_1 = tslib_1.__importDefault(require("./check_config"));
6
6
  const constants_1 = require("../config/constants");
7
7
  function createQuickPath(config, rootKey) {
8
8
  const result = {};
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const build_1 = (0, tslib_1.__importDefault)(require("./build"));
5
- const transform_1 = (0, tslib_1.__importDefault)(require("./transform"));
4
+ const build_1 = tslib_1.__importDefault(require("./build"));
5
+ const transform_1 = tslib_1.__importDefault(require("./transform"));
6
6
  const esbuild = (input, output, customOptions, callback) => {
7
7
  const entryPoints = BalmJS.utils.isString(input)
8
8
  ? [input]
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
4
+ const fs_1 = tslib_1.__importDefault(require("fs"));
5
5
  const options_1 = require("./options");
6
6
  const esTransform = (entryPoints, output, customTransformOptions, callback) => {
7
7
  const build = {
@@ -15,7 +15,7 @@ const esTransform = (entryPoints, output, customTransformOptions, callback) => {
15
15
  var e_1, _a;
16
16
  try {
17
17
  try {
18
- for (var entryPoints_1 = (0, tslib_1.__asyncValues)(entryPoints), entryPoints_1_1; entryPoints_1_1 = await entryPoints_1.next(), !entryPoints_1_1.done;) {
18
+ for (var entryPoints_1 = tslib_1.__asyncValues(entryPoints), entryPoints_1_1; entryPoints_1_1 = await entryPoints_1.next(), !entryPoints_1_1.done;) {
19
19
  const entryPoint = entryPoints_1_1.value;
20
20
  build.input = BalmJS.file.absPath(entryPoint);
21
21
  BalmJS.logger.debug('esbuild bundler - transform', {
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const entry_1 = (0, tslib_1.__importDefault)(require("./entry"));
5
- const output_1 = (0, tslib_1.__importDefault)(require("./output"));
6
- const build_1 = (0, tslib_1.__importDefault)(require("./build"));
4
+ const entry_1 = tslib_1.__importDefault(require("./entry"));
5
+ const output_1 = tslib_1.__importDefault(require("./output"));
6
+ const build_1 = tslib_1.__importDefault(require("./build"));
7
7
  const buildLibrary = async (inputOptions, outputOptions) => {
8
8
  var e_1, _a;
9
9
  const rollup = require('rollup');
@@ -15,7 +15,7 @@ const buildLibrary = async (inputOptions, outputOptions) => {
15
15
  const bundle = await rollup.rollup(rollupOptions);
16
16
  if (Array.isArray(outputOptions)) {
17
17
  try {
18
- for (var outputOptions_1 = (0, tslib_1.__asyncValues)(outputOptions), outputOptions_1_1; outputOptions_1_1 = await outputOptions_1.next(), !outputOptions_1_1.done;) {
18
+ for (var outputOptions_1 = tslib_1.__asyncValues(outputOptions), outputOptions_1_1; outputOptions_1_1 = await outputOptions_1.next(), !outputOptions_1_1.done;) {
19
19
  const outputOption = outputOptions_1_1.value;
20
20
  await (0, build_1.default)(bundle, outputOption);
21
21
  }
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const loaders_1 = (0, tslib_1.__importDefault)(require("../loaders"));
4
+ const loaders_1 = tslib_1.__importDefault(require("../loaders"));
5
5
  const constants_1 = require("../../../config/constants");
6
6
  function getDefaultPlugins(webpack, scripts) {
7
7
  const plugins = [
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const webpack_merge_1 = (0, tslib_1.__importDefault)(require("webpack-merge"));
5
- const common_1 = (0, tslib_1.__importDefault)(require("./common"));
4
+ const webpack_merge_1 = tslib_1.__importDefault(require("webpack-merge"));
5
+ const common_1 = tslib_1.__importDefault(require("./common"));
6
6
  function getDevConfig(webpack, scripts) {
7
7
  return (0, webpack_merge_1.default)((0, common_1.default)(webpack, scripts), {
8
8
  mode: 'development',
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const dev_1 = (0, tslib_1.__importDefault)(require("./dev"));
5
- const prod_1 = (0, tslib_1.__importDefault)(require("./prod"));
4
+ const dev_1 = tslib_1.__importDefault(require("./dev"));
5
+ const prod_1 = tslib_1.__importDefault(require("./prod"));
6
6
  function getDefaultConfig(webpack, scripts) {
7
7
  return BalmJS.config.env.isProd || scripts.minify || scripts.ie8
8
8
  ? (0, prod_1.default)(webpack, scripts)
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const webpack_merge_1 = (0, tslib_1.__importDefault)(require("webpack-merge"));
5
- const common_1 = (0, tslib_1.__importDefault)(require("./common"));
4
+ const webpack_merge_1 = tslib_1.__importDefault(require("webpack-merge"));
5
+ const common_1 = tslib_1.__importDefault(require("./common"));
6
6
  const constants_1 = require("../../../config/constants");
7
7
  const bundleAnalyzerReport = process.env.npm_config_report || false;
8
8
  const getCssFilename = () => `${BalmJS.config.paths.target.css}/${constants_1.ASYNC_SCRIPTS}/[name].${constants_1.HASH_NAME_PROD}.css`;
@@ -2,10 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.webpackConfig = exports.webpack = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const webpack_merge_1 = (0, tslib_1.__importDefault)(require("webpack-merge"));
6
- const entry_1 = (0, tslib_1.__importDefault)(require("./entry"));
7
- const output_1 = (0, tslib_1.__importDefault)(require("./output"));
8
- const config_1 = (0, tslib_1.__importDefault)(require("./config"));
5
+ const webpack_merge_1 = tslib_1.__importDefault(require("webpack-merge"));
6
+ const entry_1 = tslib_1.__importDefault(require("./entry"));
7
+ const output_1 = tslib_1.__importDefault(require("./output"));
8
+ const config_1 = tslib_1.__importDefault(require("./config"));
9
9
  const webpackModule = process.env.WEBPACK || require.resolve('webpack');
10
10
  const webpack = require(webpackModule);
11
11
  exports.webpack = webpack;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const webpack_merge_1 = (0, tslib_1.__importDefault)(require("webpack-merge"));
5
- const require_dir_1 = (0, tslib_1.__importDefault)(require("require-dir"));
4
+ const webpack_merge_1 = tslib_1.__importDefault(require("webpack-merge"));
5
+ const require_dir_1 = tslib_1.__importDefault(require("require-dir"));
6
6
  const LOADERS = (0, require_dir_1.default)('./rules');
7
7
  function getLoaders(customLoaders) {
8
8
  const enableDefaultLoaders = Object.assign({
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
5
- const path_1 = (0, tslib_1.__importDefault)(require("path"));
6
- const ansi_colors_1 = (0, tslib_1.__importDefault)(require("ansi-colors"));
4
+ const fs_1 = tslib_1.__importDefault(require("fs"));
5
+ const path_1 = tslib_1.__importDefault(require("path"));
6
+ const ansi_colors_1 = tslib_1.__importDefault(require("ansi-colors"));
7
7
  process.env.BALM_CWD = process.env.INIT_CWD || process.cwd();
8
- const gulpModule = `${process.env.BALM || process.env.BALM_CWD}/node_modules/gulp/index.js`;
8
+ const gulpModule = `${process.env.BALM_ROOT || process.env.BALM_CWD}/node_modules/gulp/index.js`;
9
9
  if (!fs_1.default.existsSync(gulpModule)) {
10
10
  console.error(ansi_colors_1.default.bgBlueBright('BalmJS'), ansi_colors_1.default.yellow('`balm` module not found :('));
11
11
  process.exit(1);
@@ -2,19 +2,19 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  require("./globals");
5
- const env_1 = (0, tslib_1.__importDefault)(require("./env"));
6
- const roots_1 = (0, tslib_1.__importDefault)(require("./roots"));
7
- const paths_1 = (0, tslib_1.__importDefault)(require("./paths"));
8
- const html_1 = (0, tslib_1.__importDefault)(require("./html"));
9
- const styles_1 = (0, tslib_1.__importDefault)(require("./styles"));
10
- const scripts_1 = (0, tslib_1.__importDefault)(require("./scripts"));
11
- const images_1 = (0, tslib_1.__importDefault)(require("./images"));
12
- const extras_1 = (0, tslib_1.__importDefault)(require("./extras"));
13
- const assets_1 = (0, tslib_1.__importDefault)(require("./assets"));
14
- const server_1 = (0, tslib_1.__importDefault)(require("./server"));
15
- const ftp_1 = (0, tslib_1.__importDefault)(require("./ftp"));
16
- const pwa_1 = (0, tslib_1.__importDefault)(require("./pwa"));
17
- const logs_1 = (0, tslib_1.__importDefault)(require("./logs"));
5
+ const env_1 = tslib_1.__importDefault(require("./env"));
6
+ const roots_1 = tslib_1.__importDefault(require("./roots"));
7
+ const paths_1 = tslib_1.__importDefault(require("./paths"));
8
+ const html_1 = tslib_1.__importDefault(require("./html"));
9
+ const styles_1 = tslib_1.__importDefault(require("./styles"));
10
+ const scripts_1 = tslib_1.__importDefault(require("./scripts"));
11
+ const images_1 = tslib_1.__importDefault(require("./images"));
12
+ const extras_1 = tslib_1.__importDefault(require("./extras"));
13
+ const assets_1 = tslib_1.__importDefault(require("./assets"));
14
+ const server_1 = tslib_1.__importDefault(require("./server"));
15
+ const ftp_1 = tslib_1.__importDefault(require("./ftp"));
16
+ const pwa_1 = tslib_1.__importDefault(require("./pwa"));
17
+ const logs_1 = tslib_1.__importDefault(require("./logs"));
18
18
  var LogLevel;
19
19
  (function (LogLevel) {
20
20
  LogLevel[LogLevel["Trace"] = 0] = "Trace";
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const package_json_1 = (0, tslib_1.__importDefault)(require("../../package.json"));
4
+ const package_json_1 = tslib_1.__importDefault(require("../../package.json"));
5
5
  exports.default = package_json_1.default.version;
package/tslib/hello.js CHANGED
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const events_1 = require("events");
5
- const cache_core_1 = (0, tslib_1.__importDefault)(require("./utilities/cache-core"));
5
+ const cache_core_1 = tslib_1.__importDefault(require("./utilities/cache-core"));
6
6
  global.BalmJS = {
7
7
  emitter: new events_1.EventEmitter()
8
8
  };
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const maker_1 = (0, tslib_1.__importDefault)(require("./maker"));
4
+ const maker_1 = tslib_1.__importDefault(require("./maker"));
5
5
  class BaseHooks {
6
6
  get env() {
7
7
  return BalmJS.config.env;
package/tslib/index.js CHANGED
@@ -2,10 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.version = exports.Balm = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const version_1 = (0, tslib_1.__importDefault)(require("./config/version"));
5
+ const version_1 = tslib_1.__importDefault(require("./config/version"));
6
6
  exports.version = version_1.default;
7
7
  require("./hello");
8
- const balm_1 = (0, tslib_1.__importDefault)(require("./balm"));
8
+ const balm_1 = tslib_1.__importDefault(require("./balm"));
9
9
  exports.Balm = balm_1.default;
10
10
  const balm = new balm_1.default();
11
11
  exports.default = balm;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const webpack_1 = (0, tslib_1.__importDefault)(require("./webpack"));
5
- const proxy_1 = (0, tslib_1.__importDefault)(require("./proxy"));
6
- const history_1 = (0, tslib_1.__importDefault)(require("./history"));
4
+ const webpack_1 = tslib_1.__importDefault(require("./webpack"));
5
+ const proxy_1 = tslib_1.__importDefault(require("./proxy"));
6
+ const history_1 = tslib_1.__importDefault(require("./history"));
7
7
  function getMiddlewares() {
8
8
  const canOverride = BalmJS.config.server.middlewares.every((middleware) => BalmJS.utils.isFunction(middleware) || BalmJS.utils.isObject(middleware));
9
9
  if (!canOverride) {
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getDefaultImagePlugins = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const pretty_bytes_1 = (0, tslib_1.__importDefault)(require("pretty-bytes"));
5
+ const pretty_bytes_1 = tslib_1.__importDefault(require("pretty-bytes"));
6
6
  const PLUGIN_NAME = 'imagemin';
7
7
  const defaultPlugins = ['gifsicle', 'mozjpeg', 'optipng', 'svgo'];
8
8
  const loadPlugin = (plugin, ...args) => {
@@ -1,17 +1,17 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const htmlmin_1 = (0, tslib_1.__importDefault)(require("./htmlmin"));
5
- const imagemin_1 = (0, tslib_1.__importDefault)(require("./imagemin"));
6
- const jsmin_1 = (0, tslib_1.__importDefault)(require("./jsmin"));
7
- const less_1 = (0, tslib_1.__importDefault)(require("./less"));
8
- const plumber_1 = (0, tslib_1.__importDefault)(require("./plumber"));
9
- const postcss_1 = (0, tslib_1.__importDefault)(require("./postcss"));
10
- const postcss_plugins_1 = (0, tslib_1.__importDefault)(require("./postcss-plugins"));
11
- const rename_1 = (0, tslib_1.__importDefault)(require("./rename"));
12
- const replace_1 = (0, tslib_1.__importDefault)(require("./replace"));
13
- const sass_1 = (0, tslib_1.__importDefault)(require("./sass"));
14
- const sftp_1 = (0, tslib_1.__importDefault)(require("./sftp"));
4
+ const htmlmin_1 = tslib_1.__importDefault(require("./htmlmin"));
5
+ const imagemin_1 = tslib_1.__importDefault(require("./imagemin"));
6
+ const jsmin_1 = tslib_1.__importDefault(require("./jsmin"));
7
+ const less_1 = tslib_1.__importDefault(require("./less"));
8
+ const plumber_1 = tslib_1.__importDefault(require("./plumber"));
9
+ const postcss_1 = tslib_1.__importDefault(require("./postcss"));
10
+ const postcss_plugins_1 = tslib_1.__importDefault(require("./postcss-plugins"));
11
+ const rename_1 = tslib_1.__importDefault(require("./rename"));
12
+ const replace_1 = tslib_1.__importDefault(require("./replace"));
13
+ const sass_1 = tslib_1.__importDefault(require("./sass"));
14
+ const sftp_1 = tslib_1.__importDefault(require("./sftp"));
15
15
  const plugins = {
16
16
  htmlmin: htmlmin_1.default,
17
17
  imagemin: imagemin_1.default,
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
5
- const replace_ext_1 = (0, tslib_1.__importDefault)(require("replace-ext"));
6
- const vinyl_sourcemaps_apply_1 = (0, tslib_1.__importDefault)(require("vinyl-sourcemaps-apply"));
4
+ const fs_1 = tslib_1.__importDefault(require("fs"));
5
+ const replace_ext_1 = tslib_1.__importDefault(require("replace-ext"));
6
+ const vinyl_sourcemaps_apply_1 = tslib_1.__importDefault(require("vinyl-sourcemaps-apply"));
7
7
  const PLUGIN_NAME = 'less';
8
8
  function inlineSources(sourcemap) {
9
9
  if (sourcemap.sourcesContent) {
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const stream_1 = require("stream");
5
- const vinyl_sourcemaps_apply_1 = (0, tslib_1.__importDefault)(require("vinyl-sourcemaps-apply"));
5
+ const vinyl_sourcemaps_apply_1 = tslib_1.__importDefault(require("vinyl-sourcemaps-apply"));
6
6
  const PLUGIN_NAME = 'postcss';
7
7
  function gulpPostcss(cb) {
8
8
  return function (plugins, options) {
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const stream_1 = require("stream");
5
- const replacestream_1 = (0, tslib_1.__importDefault)(require("../utilities/replacestream"));
5
+ const replacestream_1 = tslib_1.__importDefault(require("../utilities/replacestream"));
6
6
  const defaultOptions = {
7
7
  skipBinary: true
8
8
  };
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const replace_ext_1 = (0, tslib_1.__importDefault)(require("replace-ext"));
5
- const vinyl_sourcemaps_apply_1 = (0, tslib_1.__importDefault)(require("vinyl-sourcemaps-apply"));
4
+ const replace_ext_1 = tslib_1.__importDefault(require("replace-ext"));
5
+ const vinyl_sourcemaps_apply_1 = tslib_1.__importDefault(require("vinyl-sourcemaps-apply"));
6
6
  const PLUGIN_NAME = 'sass';
7
7
  const gulpSass = (options) => through2.obj((file, encoding, cb) => {
8
8
  if (file.isNull()) {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
4
+ const fs_1 = tslib_1.__importDefault(require("fs"));
5
5
  const PLUGIN_NAME = 'sftp';
6
6
  const normalizePath = (_path) => _path.replace(/\\/g, '/');
7
7
  function resolveHomePath(key) {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const balm_1 = (0, tslib_1.__importDefault)(require("./balm"));
4
+ const balm_1 = tslib_1.__importDefault(require("./balm"));
5
5
  const constants_1 = require("../../config/constants");
6
6
  class BalmStyleTask extends balm_1.default {
7
7
  constructor(name) {
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const balm_1 = (0, tslib_1.__importDefault)(require("./balm"));
5
- const balm_style_1 = (0, tslib_1.__importDefault)(require("./balm_style"));
4
+ const balm_1 = tslib_1.__importDefault(require("./balm"));
5
+ const balm_style_1 = tslib_1.__importDefault(require("./balm_style"));
6
6
  BalmJS.BalmTask = balm_1.default;
7
7
  BalmJS.BalmStyleTask = balm_style_1.default;
8
8
  BalmJS.tasks = new Map();
@@ -2,9 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  require("./foundation");
5
- const require_dir_1 = (0, tslib_1.__importDefault)(require("require-dir"));
6
- const default_1 = (0, tslib_1.__importDefault)(require("./default"));
7
- const hooks_1 = (0, tslib_1.__importDefault)(require("../hooks"));
5
+ const require_dir_1 = tslib_1.__importDefault(require("require-dir"));
6
+ const default_1 = tslib_1.__importDefault(require("./default"));
7
+ const hooks_1 = tslib_1.__importDefault(require("../hooks"));
8
8
  const PRIVATE_TASKS = (0, require_dir_1.default)('./private');
9
9
  const PUBLIC_TASKS = (0, require_dir_1.default)('./public');
10
10
  function registerTasks(recipe) {
@@ -52,7 +52,7 @@ class CleanTask extends BalmJS.BalmTask {
52
52
  get remoteAppDir() {
53
53
  return BalmJS.config.assets.subDir
54
54
  ? [BalmJS.config.assets.static]
55
- : (0, tslib_1.__classPrivateFieldGet)(this, _CleanTask_getAssetsDir, "f").call(this);
55
+ : tslib_1.__classPrivateFieldGet(this, _CleanTask_getAssetsDir, "f").call(this);
56
56
  }
57
57
  get dirInFrontend() {
58
58
  const isLocal = !path.isAbsolute(BalmJS.config.assets.root);
@@ -76,7 +76,7 @@ class CleanTask extends BalmJS.BalmTask {
76
76
  return [
77
77
  ...(BalmJS.config.env.isProd && hasBuildDir
78
78
  ? buildDirInProd
79
- : [...buildDirInDev, ...(0, tslib_1.__classPrivateFieldGet)(this, _CleanTask_getAssetsDir, "f").call(this, 'dest')])
79
+ : [...buildDirInDev, ...tslib_1.__classPrivateFieldGet(this, _CleanTask_getAssetsDir, "f").call(this, 'dest')])
80
80
  ];
81
81
  }
82
82
  }
@@ -2,7 +2,7 @@
2
2
  var _ModernizrTask_readConfig, _ModernizrTask_createDir, _ModernizrTask_generateScript;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
5
+ const fs_1 = tslib_1.__importDefault(require("fs"));
6
6
  class ModernizrTask extends BalmJS.BalmTask {
7
7
  constructor() {
8
8
  super('modernizr');
@@ -39,10 +39,10 @@ class ModernizrTask extends BalmJS.BalmTask {
39
39
  this.init();
40
40
  if (fs_1.default.existsSync(this.input)) {
41
41
  const [config] = await Promise.all([
42
- (0, tslib_1.__classPrivateFieldGet)(this, _ModernizrTask_readConfig, "f").call(this),
43
- (0, tslib_1.__classPrivateFieldGet)(this, _ModernizrTask_createDir, "f").call(this)
42
+ tslib_1.__classPrivateFieldGet(this, _ModernizrTask_readConfig, "f").call(this),
43
+ tslib_1.__classPrivateFieldGet(this, _ModernizrTask_createDir, "f").call(this)
44
44
  ]);
45
- await (0, tslib_1.__classPrivateFieldGet)(this, _ModernizrTask_generateScript, "f").call(this, config);
45
+ await tslib_1.__classPrivateFieldGet(this, _ModernizrTask_generateScript, "f").call(this, config);
46
46
  }
47
47
  else {
48
48
  BalmJS.logger.warn(`${this.name} task`, `The '${this.input}' does not exist`, {
@@ -2,7 +2,7 @@
2
2
  var _SpriteTask_tasks, _SpriteTask_getParams;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const merge_stream_1 = (0, tslib_1.__importDefault)(require("../../utilities/merge-stream"));
5
+ const merge_stream_1 = tslib_1.__importDefault(require("../../utilities/merge-stream"));
6
6
  class SpriteTask extends BalmJS.BalmTask {
7
7
  constructor() {
8
8
  super('sprite');
@@ -66,7 +66,7 @@ class SpriteTask extends BalmJS.BalmTask {
66
66
  BalmJS.logger.debug(`${this.name} task`, spriteConfig, {
67
67
  pre: true
68
68
  });
69
- spriteConfig.params = (0, tslib_1.__classPrivateFieldGet)(this, _SpriteTask_getParams, "f").call(this, spriteItem, spriteOptions);
69
+ spriteConfig.params = tslib_1.__classPrivateFieldGet(this, _SpriteTask_getParams, "f").call(this, spriteItem, spriteOptions);
70
70
  gulp.task(BalmJS.toNamespace(spriteTaskName), () => {
71
71
  const spriteData = gulp
72
72
  .src(spriteConfig.input)
@@ -78,7 +78,7 @@ class SpriteTask extends BalmJS.BalmTask {
78
78
  const cssStream = spriteData.css.pipe(gulp.dest(spriteConfig.cssOutput));
79
79
  return (0, merge_stream_1.default)(imgStream, cssStream);
80
80
  });
81
- (0, tslib_1.__classPrivateFieldGet)(this, _SpriteTask_tasks, "f").push(spriteTaskName);
81
+ tslib_1.__classPrivateFieldGet(this, _SpriteTask_tasks, "f").push(spriteTaskName);
82
82
  }
83
83
  }
84
84
  recipe(input, output, spriteOptions = {}) {
@@ -91,7 +91,7 @@ class SpriteTask extends BalmJS.BalmTask {
91
91
  }
92
92
  }
93
93
  get deps() {
94
- return (0, tslib_1.__classPrivateFieldGet)(this, _SpriteTask_tasks, "f");
94
+ return tslib_1.__classPrivateFieldGet(this, _SpriteTask_tasks, "f");
95
95
  }
96
96
  }
97
97
  _SpriteTask_tasks = new WeakMap(), _SpriteTask_getParams = new WeakMap();
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const esbuild_1 = (0, tslib_1.__importDefault)(require("../../bundler/esbuild"));
4
+ const esbuild_1 = tslib_1.__importDefault(require("../../bundler/esbuild"));
5
5
  class EsbuildTask extends BalmJS.BalmTask {
6
6
  constructor() {
7
7
  super('esbuild');
@@ -48,9 +48,9 @@ class HtmlTask extends BalmJS.BalmTask {
48
48
  ['css', 'js', 'img', 'media', 'manifest'].forEach((type) => {
49
49
  const canUpdate = type === 'manifest'
50
50
  ? BalmJS.config.pwa.enabled
51
- : (0, tslib_1.__classPrivateFieldGet)(this, _HtmlTask_hasSourcePath, "f").call(this, type);
51
+ : tslib_1.__classPrivateFieldGet(this, _HtmlTask_hasSourcePath, "f").call(this, type);
52
52
  if (canUpdate) {
53
- stream = stream.pipe((0, tslib_1.__classPrivateFieldGet)(this, _HtmlTask_updateAssetsPath, "f").call(this, type));
53
+ stream = stream.pipe(tslib_1.__classPrivateFieldGet(this, _HtmlTask_updateAssetsPath, "f").call(this, type));
54
54
  }
55
55
  });
56
56
  stream = BalmJS.config.assets.cache
@@ -60,10 +60,10 @@ class HtmlTask extends BalmJS.BalmTask {
60
60
  else {
61
61
  ['css', 'js', 'img', 'media'].forEach((type, index) => {
62
62
  const canUpdate = index > 1
63
- ? (0, tslib_1.__classPrivateFieldGet)(this, _HtmlTask_hasSourcePath, "f").call(this, type) && !BalmJS.config.inFrontend
64
- : (0, tslib_1.__classPrivateFieldGet)(this, _HtmlTask_hasSourcePath, "f").call(this, type);
63
+ ? tslib_1.__classPrivateFieldGet(this, _HtmlTask_hasSourcePath, "f").call(this, type) && !BalmJS.config.inFrontend
64
+ : tslib_1.__classPrivateFieldGet(this, _HtmlTask_hasSourcePath, "f").call(this, type);
65
65
  if (canUpdate) {
66
- stream = stream.pipe((0, tslib_1.__classPrivateFieldGet)(this, _HtmlTask_updateAssetsPath, "f").call(this, type));
66
+ stream = stream.pipe(tslib_1.__classPrivateFieldGet(this, _HtmlTask_updateAssetsPath, "f").call(this, type));
67
67
  }
68
68
  });
69
69
  stream = stream.pipe(BalmJS.file.setPublicPath());
@@ -2,7 +2,7 @@
2
2
  var _PublishTask_release;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const merge_stream_1 = (0, tslib_1.__importDefault)(require("../../utilities/merge-stream"));
5
+ const merge_stream_1 = tslib_1.__importDefault(require("../../utilities/merge-stream"));
6
6
  class PublishTask extends BalmJS.BalmTask {
7
7
  constructor() {
8
8
  super('publish');
@@ -27,11 +27,11 @@ class PublishTask extends BalmJS.BalmTask {
27
27
  const balmPublish = (callback) => {
28
28
  if (BalmJS.config.env.isProd) {
29
29
  if (BalmJS.utils.isArray(input)) {
30
- const tasks = input.map((template) => (0, tslib_1.__classPrivateFieldGet)(this, _PublishTask_release, "f").call(this, template.input, template.output, template.renameOptions));
30
+ const tasks = input.map((template) => tslib_1.__classPrivateFieldGet(this, _PublishTask_release, "f").call(this, template.input, template.output, template.renameOptions));
31
31
  return (0, merge_stream_1.default)(...tasks);
32
32
  }
33
33
  else {
34
- return (0, tslib_1.__classPrivateFieldGet)(this, _PublishTask_release, "f").call(this, input, output, renameOptions);
34
+ return tslib_1.__classPrivateFieldGet(this, _PublishTask_release, "f").call(this, input, output, renameOptions);
35
35
  }
36
36
  }
37
37
  else {
@@ -18,7 +18,7 @@ class RemoveTask extends BalmJS.BalmTask {
18
18
  const canDel = !!((BalmJS.utils.isString(input) && input.trim()) ||
19
19
  (BalmJS.utils.isArray(input) && input.length));
20
20
  if (canDel) {
21
- const files = (0, tslib_1.__classPrivateFieldGet)(this, _RemoveTask_getFiles, "f").call(this, input);
21
+ const files = tslib_1.__classPrivateFieldGet(this, _RemoveTask_getFiles, "f").call(this, input);
22
22
  BalmJS.logger.debug(`${this.name} task`, {
23
23
  files
24
24
  }, {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const rollup_1 = (0, tslib_1.__importDefault)(require("../../bundler/rollup"));
4
+ const rollup_1 = tslib_1.__importDefault(require("../../bundler/rollup"));
5
5
  class RollupTask extends BalmJS.BalmTask {
6
6
  constructor() {
7
7
  super('rollup');
@@ -2,8 +2,8 @@
2
2
  var _ServerTask_watchTask, _ServerTask_onWatch;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const detect_port_1 = (0, tslib_1.__importDefault)(require("../../utilities/detect-port"));
6
- const middlewares_1 = (0, tslib_1.__importDefault)(require("../../middlewares"));
5
+ const detect_port_1 = tslib_1.__importDefault(require("../../utilities/detect-port"));
6
+ const middlewares_1 = tslib_1.__importDefault(require("../../middlewares"));
7
7
  class ServerTask extends BalmJS.BalmTask {
8
8
  constructor() {
9
9
  super('serve');
@@ -25,18 +25,18 @@ class ServerTask extends BalmJS.BalmTask {
25
25
  `${BalmJS.config.dest.font}/**/*`,
26
26
  ...BalmJS.config.server.extraWatchFiles
27
27
  ], watchOptions).on('change', server.reload);
28
- watch(`${BalmJS.file.templateBasePath}/*.html`, watchOptions, (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, 'html', true));
29
- watch(`${BalmJS.config.src.css}/**/*.${BalmJS.config.styles.extname}`, watchOptions, (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, BalmJS.config.inFrontend ? this.styleName : 'style'));
28
+ watch(`${BalmJS.file.templateBasePath}/*.html`, watchOptions, tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, 'html', true));
29
+ watch(`${BalmJS.config.src.css}/**/*.${BalmJS.config.styles.extname}`, watchOptions, tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, BalmJS.config.inFrontend ? this.styleName : 'style'));
30
30
  if (!BalmJS.config.server.useHMR) {
31
- watch(`${BalmJS.config.src.js}/**/*`, watchOptions, (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, BalmJS.config.scripts.bundler, true));
31
+ watch(`${BalmJS.config.src.js}/**/*`, watchOptions, tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, BalmJS.config.scripts.bundler, true));
32
32
  }
33
- watch(`${BalmJS.config.src.base}/modernizr.json`, watchOptions, (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, 'modernizr'));
34
- watch(`${BalmJS.config.src.font}/**/*`, watchOptions, (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, 'font'));
33
+ watch(`${BalmJS.config.src.base}/modernizr.json`, watchOptions, tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, 'modernizr'));
34
+ watch(`${BalmJS.config.src.font}/**/*`, watchOptions, tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, 'font'));
35
35
  if (BalmJS.config.ftp.watchFiles.length) {
36
36
  watch(BalmJS.config.ftp.watchFiles, watchOptions).on('change', (path) => {
37
37
  BalmJS.logger.debug(`${this.name} task`, `File ${path} was changed`);
38
38
  BalmJS.watchFtpFile = path;
39
- (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_watchTask, "f").call(this, 'ftp', true)();
39
+ tslib_1.__classPrivateFieldGet(this, _ServerTask_watchTask, "f").call(this, 'ftp', true)();
40
40
  });
41
41
  }
42
42
  });
@@ -104,7 +104,7 @@ class ServerTask extends BalmJS.BalmTask {
104
104
  if (BalmJS.config.env.isDev) {
105
105
  BalmJS.server = server.init(bsOptions);
106
106
  if (BalmJS.config.useDefaults) {
107
- (0, tslib_1.__classPrivateFieldGet)(this, _ServerTask_onWatch, "f").call(this);
107
+ tslib_1.__classPrivateFieldGet(this, _ServerTask_onWatch, "f").call(this);
108
108
  }
109
109
  else {
110
110
  BalmJS.watching = true;
@@ -26,8 +26,8 @@ class UrlTask extends BalmJS.BalmTask {
26
26
  const balmUrl = () => {
27
27
  this.init(input, output);
28
28
  return this.src
29
- .pipe((0, tslib_1.__classPrivateFieldGet)(this, _UrlTask_urlProcessing, "f").call(this, 'img'))
30
- .pipe((0, tslib_1.__classPrivateFieldGet)(this, _UrlTask_urlProcessing, "f").call(this, 'font'))
29
+ .pipe(tslib_1.__classPrivateFieldGet(this, _UrlTask_urlProcessing, "f").call(this, 'img'))
30
+ .pipe(tslib_1.__classPrivateFieldGet(this, _UrlTask_urlProcessing, "f").call(this, 'font'))
31
31
  .pipe(gulp.dest(this.output));
32
32
  };
33
33
  return balmUrl;
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const webpack_1 = require("../../bundler/webpack");
5
- const compiling_1 = (0, tslib_1.__importDefault)(require("../../utilities/compiling"));
5
+ const compiling_1 = tslib_1.__importDefault(require("../../utilities/compiling"));
6
6
  class WebpackTask extends BalmJS.BalmTask {
7
7
  constructor() {
8
8
  super('webpack');
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const os_1 = (0, tslib_1.__importDefault)(require("os"));
4
+ const os_1 = tslib_1.__importDefault(require("os"));
5
5
  const platform = os_1.default.platform();
6
6
  function getInterfaceName() {
7
7
  let val = 'eth';
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const module_1 = (0, tslib_1.__importDefault)(require("module"));
5
- const path_1 = (0, tslib_1.__importDefault)(require("path"));
4
+ const module_1 = tslib_1.__importDefault(require("module"));
5
+ const path_1 = tslib_1.__importDefault(require("path"));
6
6
  const os_1 = require("os");
7
7
  const fs_1 = require("fs");
8
- const loading_1 = (0, tslib_1.__importDefault)(require("./loading"));
8
+ const loading_1 = tslib_1.__importDefault(require("./loading"));
9
9
  const _require = module_1.default.prototype.require;
10
10
  const SAVE_FILE = path_1.default.join((0, os_1.homedir)(), process.env.BALM_CORE_CACHE || '.balm-core-cache.json');
11
11
  function cacheBalmCore() {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const ansi_colors_1 = (0, tslib_1.__importDefault)(require("ansi-colors"));
4
+ const ansi_colors_1 = tslib_1.__importDefault(require("ansi-colors"));
5
5
  const COLOR = {
6
6
  PREFIX: 'bg',
7
7
  SUFFIX: 'Bright'
@@ -2,19 +2,19 @@
2
2
  var _BalmCompiling_firstCompile;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const loading_1 = (0, tslib_1.__importDefault)(require("./loading"));
5
+ const loading_1 = tslib_1.__importDefault(require("./loading"));
6
6
  class BalmCompiling {
7
7
  constructor() {
8
8
  _BalmCompiling_firstCompile.set(this, true);
9
9
  }
10
10
  start() {
11
- if ((0, tslib_1.__classPrivateFieldGet)(this, _BalmCompiling_firstCompile, "f")) {
11
+ if (tslib_1.__classPrivateFieldGet(this, _BalmCompiling_firstCompile, "f")) {
12
12
  loading_1.default.render('Compiling to JS...');
13
13
  }
14
14
  }
15
15
  stop() {
16
- if ((0, tslib_1.__classPrivateFieldGet)(this, _BalmCompiling_firstCompile, "f")) {
17
- (0, tslib_1.__classPrivateFieldSet)(this, _BalmCompiling_firstCompile, false, "f");
16
+ if (tslib_1.__classPrivateFieldGet(this, _BalmCompiling_firstCompile, "f")) {
17
+ tslib_1.__classPrivateFieldSet(this, _BalmCompiling_firstCompile, false, "f");
18
18
  loading_1.default.clear();
19
19
  }
20
20
  }
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const net_1 = (0, tslib_1.__importDefault)(require("net"));
5
- const address_1 = (0, tslib_1.__importDefault)(require("./address"));
4
+ const net_1 = tslib_1.__importDefault(require("net"));
5
+ const address_1 = tslib_1.__importDefault(require("./address"));
6
6
  const UTIL_NAME = 'detect port';
7
7
  const MAX_PORT = 65535;
8
8
  function listen(port, host, callback) {
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_1 = (0, tslib_1.__importDefault)(require("fs"));
5
- const public_url_1 = (0, tslib_1.__importDefault)(require("./public-url"));
4
+ const fs_1 = tslib_1.__importDefault(require("fs"));
5
+ const public_url_1 = tslib_1.__importDefault(require("./public-url"));
6
6
  const constants_1 = require("../config/constants");
7
7
  const appDirectory = fs_1.default.realpathSync(process.cwd());
8
8
  const resolveApp = (relativePath) => path.resolve(appDirectory, relativePath);
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const utils_1 = (0, tslib_1.__importDefault)(require("./utils"));
5
- const logger_1 = (0, tslib_1.__importDefault)(require("./logger"));
6
- const file_1 = (0, tslib_1.__importDefault)(require("./file"));
7
- const namespace_1 = (0, tslib_1.__importDefault)(require("./namespace"));
4
+ const utils_1 = tslib_1.__importDefault(require("./utils"));
5
+ const logger_1 = tslib_1.__importDefault(require("./logger"));
6
+ const file_1 = tslib_1.__importDefault(require("./file"));
7
+ const namespace_1 = tslib_1.__importDefault(require("./namespace"));
8
8
  BalmJS.utils = utils_1.default;
9
9
  BalmJS.logger = logger_1.default;
10
10
  BalmJS.file = file_1.default;
@@ -2,9 +2,9 @@
2
2
  var _BalmLoading_stream, _BalmLoading_frameIndex, _BalmLoading_frameCount;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const readline_1 = (0, tslib_1.__importDefault)(require("readline"));
6
- const spinner_1 = (0, tslib_1.__importDefault)(require("../config/spinner"));
7
- const version_1 = (0, tslib_1.__importDefault)(require("../config/version"));
5
+ const readline_1 = tslib_1.__importDefault(require("readline"));
6
+ const spinner_1 = tslib_1.__importDefault(require("../config/spinner"));
7
+ const version_1 = tslib_1.__importDefault(require("../config/version"));
8
8
  class BalmLoading {
9
9
  constructor() {
10
10
  _BalmLoading_stream.set(this, process.stderr);
@@ -13,17 +13,17 @@ class BalmLoading {
13
13
  }
14
14
  get frame() {
15
15
  var _a;
16
- const currentFrame = spinner_1.default.frames[(0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_frameIndex, "f")];
17
- (0, tslib_1.__classPrivateFieldSet)(this, _BalmLoading_frameIndex, (0, tslib_1.__classPrivateFieldSet)(this, _BalmLoading_frameIndex, (_a = (0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_frameIndex, "f"), ++_a), "f") % (0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_frameCount, "f"), "f");
16
+ const currentFrame = spinner_1.default.frames[tslib_1.__classPrivateFieldGet(this, _BalmLoading_frameIndex, "f")];
17
+ tslib_1.__classPrivateFieldSet(this, _BalmLoading_frameIndex, tslib_1.__classPrivateFieldSet(this, _BalmLoading_frameIndex, (_a = tslib_1.__classPrivateFieldGet(this, _BalmLoading_frameIndex, "f"), ++_a), "f") % tslib_1.__classPrivateFieldGet(this, _BalmLoading_frameCount, "f"), "f");
18
18
  return currentFrame;
19
19
  }
20
20
  clear() {
21
- readline_1.default.clearLine((0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_stream, "f"), 0);
22
- readline_1.default.cursorTo((0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_stream, "f"), 0);
21
+ readline_1.default.clearLine(tslib_1.__classPrivateFieldGet(this, _BalmLoading_stream, "f"), 0);
22
+ readline_1.default.cursorTo(tslib_1.__classPrivateFieldGet(this, _BalmLoading_stream, "f"), 0);
23
23
  }
24
24
  render(text = `${this.frame} BalmJS is initializing...`) {
25
25
  this.clear();
26
- (0, tslib_1.__classPrivateFieldGet)(this, _BalmLoading_stream, "f").write(text);
26
+ tslib_1.__classPrivateFieldGet(this, _BalmLoading_stream, "f").write(text);
27
27
  }
28
28
  succeed() {
29
29
  this.clear();
@@ -2,9 +2,9 @@
2
2
  var _Logger_log;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  const tslib_1 = require("tslib");
5
- const util_1 = (0, tslib_1.__importDefault)(require("util"));
6
- const fancy_log_1 = (0, tslib_1.__importDefault)(require("fancy-log"));
7
- const color_1 = (0, tslib_1.__importDefault)(require("./color"));
5
+ const util_1 = tslib_1.__importDefault(require("util"));
6
+ const fancy_log_1 = tslib_1.__importDefault(require("fancy-log"));
7
+ const color_1 = tslib_1.__importDefault(require("./color"));
8
8
  const LOG = {
9
9
  FORMAT: '%s %s %s',
10
10
  PREFIX: (0, color_1.default)('BalmJS', {
@@ -57,7 +57,7 @@ class Logger {
57
57
  }, options);
58
58
  if (BalmJS.config.logs.level <= logOptions.logLevel) {
59
59
  console.log(LOG.beginning);
60
- (0, fancy_log_1.default)(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.OK), (0, tslib_1.__classPrivateFieldGet)(this, _Logger_log, "f").call(this, message, logOptions.pre));
60
+ (0, fancy_log_1.default)(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.OK), tslib_1.__classPrivateFieldGet(this, _Logger_log, "f").call(this, message, logOptions.pre));
61
61
  console.log(LOG.end);
62
62
  }
63
63
  }
@@ -66,7 +66,7 @@ class Logger {
66
66
  logLevel: BalmJS.LogLevel.Debug
67
67
  }, options);
68
68
  if (BalmJS.config.logs.level <= logOptions.logLevel) {
69
- fancy_log_1.default.info(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.DEBUG), (0, tslib_1.__classPrivateFieldGet)(this, _Logger_log, "f").call(this, message, logOptions.pre));
69
+ fancy_log_1.default.info(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.DEBUG), tslib_1.__classPrivateFieldGet(this, _Logger_log, "f").call(this, message, logOptions.pre));
70
70
  }
71
71
  }
72
72
  info(label, message, options = {}) {
@@ -74,7 +74,7 @@ class Logger {
74
74
  logLevel: BalmJS.LogLevel.Info
75
75
  }, options);
76
76
  if (BalmJS.config.logs.level <= logOptions.logLevel) {
77
- fancy_log_1.default.info(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.INFO), (0, tslib_1.__classPrivateFieldGet)(this, _Logger_log, "f").call(this, message, logOptions.pre));
77
+ fancy_log_1.default.info(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.INFO), tslib_1.__classPrivateFieldGet(this, _Logger_log, "f").call(this, message, logOptions.pre));
78
78
  }
79
79
  }
80
80
  warn(label, message, options = {}) {
@@ -82,7 +82,7 @@ class Logger {
82
82
  logLevel: BalmJS.LogLevel.Warn
83
83
  }, options);
84
84
  if (BalmJS.config.logs.level <= logOptions.logLevel) {
85
- fancy_log_1.default.warn(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.WARN), (0, tslib_1.__classPrivateFieldGet)(this, _Logger_log, "f").call(this, message, logOptions.pre));
85
+ fancy_log_1.default.warn(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.WARN), tslib_1.__classPrivateFieldGet(this, _Logger_log, "f").call(this, message, logOptions.pre));
86
86
  }
87
87
  }
88
88
  error(label, message, options = {}) {
@@ -91,7 +91,7 @@ class Logger {
91
91
  pre: false
92
92
  }, options);
93
93
  if (BalmJS.config.logs.level <= logOptions.logLevel) {
94
- fancy_log_1.default.error(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.ERROR), (0, tslib_1.__classPrivateFieldGet)(this, _Logger_log, "f").call(this, message, logOptions.pre));
94
+ fancy_log_1.default.error(LOG.FORMAT, LOG.PREFIX, (0, color_1.default)(`<${label}>`, LOG.ERROR), tslib_1.__classPrivateFieldGet(this, _Logger_log, "f").call(this, message, logOptions.pre));
95
95
  }
96
96
  }
97
97
  }
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const escape_string_regexp_1 = (0, tslib_1.__importDefault)(require("./escape-string-regexp"));
4
+ const escape_string_regexp_1 = tslib_1.__importDefault(require("./escape-string-regexp"));
5
5
  function createReplaceFn(replace, isRegEx) {
6
6
  function regexReplaceFunction(...args) {
7
7
  let newReplace = replace;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const typeof_1 = (0, tslib_1.__importDefault)(require("./typeof"));
4
+ const typeof_1 = tslib_1.__importDefault(require("./typeof"));
5
5
  function isString(str) {
6
6
  return (0, typeof_1.default)(str) === 'string';
7
7
  }