Skip to content

Commit

Permalink
chore(release): prepare release 3.0.0-rc.1
Browse files Browse the repository at this point in the history
  • Loading branch information
bigopon committed May 21, 2022
1 parent 5d183f8 commit 185cf47
Show file tree
Hide file tree
Showing 39 changed files with 27 additions and 85 deletions.
2 changes: 0 additions & 2 deletions dist/dom.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });

//# sourceMappingURL=dom.js.map
1 change: 0 additions & 1 deletion dist/dom.js.map

This file was deleted.

2 changes: 0 additions & 2 deletions dist/feature.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });

//# sourceMappingURL=feature.js.map
1 change: 0 additions & 1 deletion dist/feature.js.map

This file was deleted.

2 changes: 0 additions & 2 deletions dist/global.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });

//# sourceMappingURL=global.js.map
1 change: 0 additions & 1 deletion dist/global.js.map

This file was deleted.

18 changes: 4 additions & 14 deletions dist/index.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
"use strict";
/// <reference path="./nodejs-global.ts" />
Object.defineProperty(exports, "__esModule", { value: true });
exports.reset = exports.globalize = exports.initialize = exports.ensurePerformance = void 0;
const aurelia_pal_1 = require("aurelia-pal");
const nodejs_pal_builder_1 = require("./nodejs-pal-builder");
var nodejs_pal_builder_2 = require("./nodejs-pal-builder");
exports.ensurePerformance = nodejs_pal_builder_2.ensurePerformance;
/**
* Initializes the PAL with the NodeJS-targeted implementation.
*/
Object.defineProperty(exports, "ensurePerformance", { enumerable: true, get: function () { return nodejs_pal_builder_2.ensurePerformance; } });
function initialize() {
if (aurelia_pal_1.isInitialized) {
return;
}
let pal = nodejs_pal_builder_1.buildPal();
aurelia_pal_1.initializePAL((platform, feature, dom) => {
let pal = (0, nodejs_pal_builder_1.buildPal)();
(0, aurelia_pal_1.initializePAL)((platform, feature, dom) => {
Object.assign(platform, pal.platform);
Object.setPrototypeOf(platform, pal.platform.constructor.prototype);
Object.assign(dom, pal.dom);
Expand Down Expand Up @@ -67,16 +64,11 @@ function initialize() {
});
}
exports.initialize = initialize;
// snippet copied from https://github.com/lukechilds/browser-env
function createBrowserGlobals() {
Object.getOwnPropertyNames(aurelia_pal_1.PLATFORM.global)
// avoid conflict with nodejs globals
.filter(prop => typeof global[prop] === 'undefined')
.forEach(prop => global[prop] = aurelia_pal_1.PLATFORM.global[prop]);
}
/**
* @description initializes and makes variables like 'window' into NodeJS globals
*/
function globalize() {
initialize();
createBrowserGlobals();
Expand All @@ -102,5 +94,3 @@ function reset(window) {
}
}
exports.reset = reset;

//# sourceMappingURL=index.js.map
1 change: 0 additions & 1 deletion dist/index.js.map

This file was deleted.

6 changes: 1 addition & 5 deletions dist/nodejs-dom.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/**
* Represents the core APIs of the DOM.
*/
exports.NodeJsDom = void 0;
class NodeJsDom {
constructor(global) {
this.global = global;
Expand Down Expand Up @@ -108,5 +106,3 @@ class NodeJsDom {
}
}
exports.NodeJsDom = NodeJsDom;

//# sourceMappingURL=nodejs-dom.js.map
1 change: 0 additions & 1 deletion dist/nodejs-dom.js.map

This file was deleted.

5 changes: 2 additions & 3 deletions dist/nodejs-feature.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.NodeJsFeature = void 0;
class NodeJsFeature {
constructor(global) {
this.global = global;
this.shadowDOM = this.global.window.HTMLElement.prototype.attachShadow != undefined;
this.scopedCSS = 'scoped' in this.global.document.createElement('style');
this.htmlTemplateElement = true;
this.mutationObserver = true; // partial
this.mutationObserver = true;
}
}
exports.NodeJsFeature = NodeJsFeature;

//# sourceMappingURL=nodejs-feature.js.map
1 change: 0 additions & 1 deletion dist/nodejs-feature.js.map

This file was deleted.

3 changes: 0 additions & 3 deletions dist/nodejs-global.js
Original file line number Diff line number Diff line change
@@ -1,3 +0,0 @@


//# sourceMappingURL=nodejs-global.js.map
1 change: 0 additions & 1 deletion dist/nodejs-global.js.map

This file was deleted.

5 changes: 1 addition & 4 deletions dist/nodejs-pal-builder.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ensurePerformance = exports.buildPal = void 0;
const nodejs_platform_1 = require("./nodejs-platform");
const nodejs_feature_1 = require("./nodejs-feature");
const nodejs_dom_1 = require("./nodejs-dom");
const jsdom_1 = require("jsdom");
function buildPal() {
// https://github.com/jsdom/jsdom/issues/2304
// set url to enable global var localStorage and sessionStorage
var jsdom = new jsdom_1.JSDOM(undefined, { url: "http://localhost/" });
var global = jsdom.window;
ensurePerformance(global.window);
Expand Down Expand Up @@ -120,5 +119,3 @@ function ensurePerformance(window) {
}
}
exports.ensurePerformance = ensurePerformance;

//# sourceMappingURL=nodejs-pal-builder.js.map
Loading

0 comments on commit 185cf47

Please sign in to comment.