swico 0.8.3-beta5 → 0.8.3-beta6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swico",
3
- "version": "0.8.3-beta5",
3
+ "version": "0.8.3-beta6",
4
4
  "description": "Simple, efficient, and practical front-end framework",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
@@ -137,6 +137,7 @@ var createCompileListener = function (compiler) {
137
137
  tools_1.toast.info('Compiling...', { wrap: false });
138
138
  });
139
139
  compiler.hooks.done.tap('done', function (stats) {
140
+ console.log('done');
140
141
  var info = stats === null || stats === void 0 ? void 0 : stats.toJson();
141
142
  if (stats === null || stats === void 0 ? void 0 : stats.hasErrors()) {
142
143
  tools_1.toast.error(info === null || info === void 0 ? void 0 : info.errors.map(function (item) { return item.message || item.stack; }));
@@ -147,6 +148,15 @@ var createCompileListener = function (compiler) {
147
148
  }
148
149
  tools_1.toast.info("Compiled complete in ".concat(info === null || info === void 0 ? void 0 : info.time, "ms"));
149
150
  });
151
+ compiler.hooks.afterCompile.tap('afterCompile', function (compilation) {
152
+ var errors = compilation.errors, endTime = compilation.endTime;
153
+ console.log('afterCompile');
154
+ if ((errors === null || errors === void 0 ? void 0 : errors.length) > 0) {
155
+ tools_1.toast.error(errors.map(function (item) { return item.message || item.stack; }));
156
+ return;
157
+ }
158
+ tools_1.toast.info("afterCompile in ".concat(endTime, "ms"));
159
+ });
150
160
  };
151
161
  function start() {
152
162
  return __awaiter(this, void 0, void 0, function () {