chore(build): replace traceur-runtime with es6-shim.
This removes traceur as a dependency for the t push -f angular2 build. Closes #4148
This commit is contained in:
parent
309944931f
commit
cac25fe003
121
gulpfile.js
121
gulpfile.js
|
@ -91,19 +91,18 @@ var treatTestErrorsAsFatal = true;
|
||||||
|
|
||||||
function runJasmineTests(globs, done) {
|
function runJasmineTests(globs, done) {
|
||||||
var args = ['--'].concat(globs);
|
var args = ['--'].concat(globs);
|
||||||
fork('./tools/traceur-jasmine', args, {
|
fork('./tools/cjs-jasmine', args, {stdio: 'inherit'})
|
||||||
stdio: 'inherit'
|
.on('close', function jasmineCloseHandler(exitCode) {
|
||||||
}).on('close', function jasmineCloseHandler(exitCode) {
|
if (exitCode && treatTestErrorsAsFatal) {
|
||||||
if (exitCode && treatTestErrorsAsFatal) {
|
var err = new Error('Jasmine tests failed');
|
||||||
var err = new Error('Jasmine tests failed');
|
// Mark the error for gulp similar to how gulp-utils.PluginError does it.
|
||||||
// Mark the error for gulp similar to how gulp-utils.PluginError does it.
|
// The stack is not useful in this context.
|
||||||
// The stack is not useful in this context.
|
err.showStack = false;
|
||||||
err.showStack = false;
|
done(err);
|
||||||
done(err);
|
} else {
|
||||||
} else {
|
done();
|
||||||
done();
|
}
|
||||||
}
|
});
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Note: when DART_SDK is not found, all gulp tasks ending with `.dart` will be skipped.
|
// Note: when DART_SDK is not found, all gulp tasks ending with `.dart` will be skipped.
|
||||||
|
@ -141,11 +140,8 @@ var BENCHPRESS_BUNDLE_CONFIG = {
|
||||||
'angular2'
|
'angular2'
|
||||||
],
|
],
|
||||||
excludes: [
|
excludes: [
|
||||||
'traceur',
|
|
||||||
'traceur/bin/traceur-runtime',
|
|
||||||
'reflect-metadata',
|
'reflect-metadata',
|
||||||
'selenium-webdriver',
|
'selenium-webdriver',
|
||||||
'rtts_assert',
|
|
||||||
'zone.js'
|
'zone.js'
|
||||||
],
|
],
|
||||||
ignore: [
|
ignore: [
|
||||||
|
@ -837,47 +833,46 @@ gulp.task('build/pure-packages.dart', function() {
|
||||||
])
|
])
|
||||||
.pipe(gulp.dest(path.join(CONFIG.dest.dart, 'angular2')));
|
.pipe(gulp.dest(path.join(CONFIG.dest.dart, 'angular2')));
|
||||||
|
|
||||||
var moveStream = gulp
|
var moveStream = gulp.src([
|
||||||
.src([
|
'modules_dart/**/*.dart',
|
||||||
'modules_dart/**/*.dart',
|
'modules_dart/**/pubspec.yaml',
|
||||||
'modules_dart/**/pubspec.yaml',
|
'!modules_dart/transform/**'
|
||||||
'!modules_dart/transform/**'
|
])
|
||||||
])
|
.pipe(through2.obj(function(file, enc, done) {
|
||||||
.pipe(through2.obj(function(file, enc, done) {
|
if (/pubspec.yaml$/.test(file.path)) {
|
||||||
if (file.path.endsWith('pubspec.yaml')) {
|
// Pure packages specify dependency_overrides relative to
|
||||||
// Pure packages specify dependency_overrides relative to
|
// `modules_dart`, so they have to walk up and into `dist`.
|
||||||
// `modules_dart`, so they have to walk up and into `dist`.
|
//
|
||||||
//
|
// Example:
|
||||||
// Example:
|
//
|
||||||
//
|
// dependency_overrides:
|
||||||
// dependency_overrides:
|
// angular2:
|
||||||
// angular2:
|
// path: ../../dist/dart/angular2
|
||||||
// path: ../../dist/dart/angular2
|
//
|
||||||
//
|
// When we copy a pure package into `dist` the relative path
|
||||||
// When we copy a pure package into `dist` the relative path
|
// must be updated. The code below replaces paths accordingly.
|
||||||
// must be updated. The code below replaces paths accordingly.
|
// So the example above is turned into:
|
||||||
// So the example above is turned into:
|
//
|
||||||
//
|
// dependency_overrides:
|
||||||
// dependency_overrides:
|
// angular2:
|
||||||
// angular2:
|
// path: ../angular2
|
||||||
// path: ../angular2
|
//
|
||||||
//
|
var pubspec = yaml.safeLoad(file.contents.toString());
|
||||||
var pubspec = yaml.safeLoad(file.contents.toString());
|
var overrides = pubspec.dependency_overrides;
|
||||||
var overrides = pubspec.dependency_overrides;
|
if (overrides) {
|
||||||
if (overrides) {
|
Object.keys(overrides).forEach(function(pkg) {
|
||||||
Object.keys(overrides).forEach(function(pkg) {
|
var overridePath = overrides[pkg].path;
|
||||||
var overridePath = overrides[pkg].path;
|
if ((new RegExp('^' + originalPrefix)).test(overridePath)) {
|
||||||
if (overridePath.startsWith(originalPrefix)) {
|
overrides[pkg].path = overridePath.replace(originalPrefix, '../');
|
||||||
overrides[pkg].path = overridePath.replace(originalPrefix, '../');
|
}
|
||||||
}
|
});
|
||||||
});
|
file.contents = new Buffer(yaml.safeDump(pubspec));
|
||||||
file.contents = new Buffer(yaml.safeDump(pubspec));
|
}
|
||||||
}
|
}
|
||||||
}
|
this.push(file);
|
||||||
this.push(file);
|
done();
|
||||||
done();
|
}))
|
||||||
}))
|
.pipe(gulp.dest(CONFIG.dest.dart));
|
||||||
.pipe(gulp.dest(CONFIG.dest.dart));
|
|
||||||
|
|
||||||
|
|
||||||
return merge2(transformStream, moveStream);
|
return merge2(transformStream, moveStream);
|
||||||
|
@ -1145,13 +1140,11 @@ gulp.task('!bundle.js.min.deps', ['!bundle.js.min'], function() {
|
||||||
});
|
});
|
||||||
|
|
||||||
var JS_DEV_DEPS = [
|
var JS_DEV_DEPS = [
|
||||||
licenseWrap('node_modules/zone.js/LICENSE', true),
|
licenseWrap('node_modules/zone.js/LICENSE', true),
|
||||||
'node_modules/zone.js/dist/zone-microtask.js',
|
'node_modules/zone.js/dist/zone-microtask.js',
|
||||||
'node_modules/zone.js/dist/long-stack-trace-zone.js',
|
'node_modules/zone.js/dist/long-stack-trace-zone.js',
|
||||||
licenseWrap('node_modules/reflect-metadata/LICENSE', true),
|
licenseWrap('node_modules/reflect-metadata/LICENSE', true),
|
||||||
'node_modules/reflect-metadata/Reflect.js',
|
'node_modules/reflect-metadata/Reflect.js'
|
||||||
// traceur-runtime is always first in the bundle
|
|
||||||
licenseWrap('node_modules/traceur/LICENSE', true)
|
|
||||||
];
|
];
|
||||||
|
|
||||||
// Splice in RX license if rx is in the bundle.
|
// Splice in RX license if rx is in the bundle.
|
||||||
|
|
|
@ -17,7 +17,7 @@ module.exports = function(config) {
|
||||||
'node_modules/zone.js/dist/long-stack-trace-zone.js',
|
'node_modules/zone.js/dist/long-stack-trace-zone.js',
|
||||||
'node_modules/zone.js/dist/jasmine-patch.js',
|
'node_modules/zone.js/dist/jasmine-patch.js',
|
||||||
|
|
||||||
'node_modules/traceur/bin/traceur-runtime.js',
|
'node_modules/es6-shim/es6-shim.js',
|
||||||
// Including systemjs because it defines `__eval`, which produces correct stack traces.
|
// Including systemjs because it defines `__eval`, which produces correct stack traces.
|
||||||
'modules/angular2/src/test_lib/shims_for_IE.js',
|
'modules/angular2/src/test_lib/shims_for_IE.js',
|
||||||
'node_modules/systemjs/dist/system.src.js',
|
'node_modules/systemjs/dist/system.src.js',
|
||||||
|
@ -28,10 +28,7 @@ module.exports = function(config) {
|
||||||
{pattern: 'modules/**/test/**/static_assets/**', included: false, watched: false}
|
{pattern: 'modules/**/test/**/static_assets/**', included: false, watched: false}
|
||||||
],
|
],
|
||||||
|
|
||||||
exclude: [
|
exclude: ['dist/js/dev/es5/**/e2e_test/**', 'dist/angular1_router.js'],
|
||||||
'dist/js/dev/es5/**/e2e_test/**',
|
|
||||||
'dist/angular1_router.js'
|
|
||||||
],
|
|
||||||
|
|
||||||
customLaunchers: sauceConf.customLaunchers,
|
customLaunchers: sauceConf.customLaunchers,
|
||||||
|
|
||||||
|
|
|
@ -21,8 +21,8 @@ var files = [
|
||||||
var PRELUDE = '(function(){\n';
|
var PRELUDE = '(function(){\n';
|
||||||
var POSTLUDE = '\n}());\n';
|
var POSTLUDE = '\n}());\n';
|
||||||
var FACADES = fs.readFileSync(__dirname + '/lib/facades.es5', 'utf8');
|
var FACADES = fs.readFileSync(__dirname + '/lib/facades.es5', 'utf8');
|
||||||
var TRACEUR_RUNTIME = fs.readFileSync(__dirname + '/../../node_modules/traceur/bin/traceur-runtime.js', 'utf8');
|
|
||||||
var DIRECTIVES = fs.readFileSync(__dirname + '/src/ng_outlet.js', 'utf8');
|
var DIRECTIVES = fs.readFileSync(__dirname + '/src/ng_outlet.js', 'utf8');
|
||||||
|
var ES6_SHIM = fs.readFileSync(__dirname + '/../../node_modules/es6-shim/es6-shim.js', 'utf8');
|
||||||
function main() {
|
function main() {
|
||||||
var dir = __dirname + '/../angular2/src/router/';
|
var dir = __dirname + '/../angular2/src/router/';
|
||||||
|
|
||||||
|
@ -85,7 +85,7 @@ function main() {
|
||||||
"return router;"
|
"return router;"
|
||||||
].join('\n'));
|
].join('\n'));
|
||||||
|
|
||||||
return PRELUDE + TRACEUR_RUNTIME + DIRECTIVES + out + POSTLUDE;
|
return PRELUDE + ES6_SHIM + DIRECTIVES + out + POSTLUDE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -128,7 +128,7 @@ var StringMapWrapper = {
|
||||||
},
|
},
|
||||||
|
|
||||||
forEach: function (m, fn) {
|
forEach: function (m, fn) {
|
||||||
for (prop in m) {
|
for (var prop in m) {
|
||||||
if (m.hasOwnProperty(prop)) {
|
if (m.hasOwnProperty(prop)) {
|
||||||
fn(m[prop], prop);
|
fn(m[prop], prop);
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@ To bootstrap Hello World in a WebWorker we do the following in TypeScript
|
||||||
```HTML
|
```HTML
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<script src="https://github.jspm.io/jmcriffey/bower-traceur-runtime@0.0.87/traceur-runtime.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/es6-shim/0.33.3/es6-shim.js"></script>
|
||||||
<script src="https://jspm.io/system@0.16.js"></script>
|
<script src="https://jspm.io/system@0.16.js"></script>
|
||||||
<script src="angular2/web_worker/ui.js"></script>
|
<script src="angular2/web_worker/ui.js"></script>
|
||||||
</head>
|
</head>
|
||||||
|
@ -44,7 +44,7 @@ bootstrap("loader.js");
|
||||||
```
|
```
|
||||||
```JavaScript
|
```JavaScript
|
||||||
// loader.js
|
// loader.js
|
||||||
importScripts("https://github.jspm.io/jmcriffey/bower-traceur-runtime@0.0.87/traceur-runtime.js", "https://jspm.io/system@0.16.js", "angular2/web_worker/worker.js");
|
importScripts("https://cdnjs.cloudflare.com/ajax/libs/es6-shim/0.33.3/es6-shim.js", "https://jspm.io/system@0.16.js", "angular2/web_worker/worker.js");
|
||||||
System.import("app");
|
System.import("app");
|
||||||
```
|
```
|
||||||
```TypeScript
|
```TypeScript
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
interface PromiseLike<T> extends Thenable<T> {}
|
interface PromiseLike<T> extends Thenable<T> {}
|
||||||
|
|
||||||
// Extend the ES5 standard library with some ES6 features we polyfill at runtime
|
// Extend the ES5 standard library with some ES6 features we polyfill at runtime
|
||||||
// by loading traceur-runtime.js
|
// by loading es6-shim.js
|
||||||
|
|
||||||
// These are mostly copied from lib.es6.d.ts
|
// These are mostly copied from lib.es6.d.ts
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// Index to be used if Http is ever configured as a standalone npm package.
|
// Index to be used if Http is ever configured as a standalone npm package.
|
||||||
// require('reflect-metadata');
|
// require('reflect-metadata');
|
||||||
// require('traceur-runtime');
|
// require('es6-shim');
|
||||||
// import {HTTP_BINDINGS, JSONP_BINDINGS, Http, Jsonp} from './http';
|
// import {HTTP_BINDINGS, JSONP_BINDINGS, Http, Jsonp} from './http';
|
||||||
// import {Injector} from 'angular2/angular2';
|
// import {Injector} from 'angular2/angular2';
|
||||||
// export * from './http';
|
// export * from './http';
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
require('reflect-metadata');
|
require('reflect-metadata');
|
||||||
require('traceur/bin/traceur-runtime');
|
require('es6-shim');
|
||||||
module.exports = require('./benchpress.js');
|
module.exports = require('./benchpress.js');
|
||||||
// when bundling benchpress to one file, this is used
|
// when bundling benchpress to one file, this is used
|
||||||
// for getting exports out of browserify's scope.
|
// for getting exports out of browserify's scope.
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
"repository": <%= JSON.stringify(packageJson.repository) %>,
|
"repository": <%= JSON.stringify(packageJson.repository) %>,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"angular2": "<%= packageJson.version %>",
|
"angular2": "<%= packageJson.version %>",
|
||||||
"traceur": "<%= packageJson.dependencies.traceur %>",
|
|
||||||
"selenium-webdriver": "<%= packageJson.dependencies['selenium-webdriver'] %>",
|
"selenium-webdriver": "<%= packageJson.dependencies['selenium-webdriver'] %>",
|
||||||
"reflect-metadata": "<%= packageJson.dependencies['reflect-metadata'] %>"
|
"reflect-metadata": "<%= packageJson.dependencies['reflect-metadata'] %>"
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/// <reference path="../../../angular2/typings/node/node.d.ts" />
|
/// <reference path="../../../angular2/typings/node/node.d.ts" />
|
||||||
require('traceur/bin/traceur-runtime.js');
|
require('es6-shim/es6-shim.js');
|
||||||
require('reflect-metadata');
|
require('reflect-metadata');
|
||||||
var testHelper = require('../../src/firefox_extension/lib/test_helper.js');
|
var testHelper = require('../../src/firefox_extension/lib/test_helper.js');
|
||||||
|
|
||||||
|
|
|
@ -2999,6 +2999,9 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"es6-shim": {
|
||||||
|
"version": "0.33.3"
|
||||||
|
},
|
||||||
"event-stream": {
|
"event-stream": {
|
||||||
"version": "3.3.1",
|
"version": "3.3.1",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
@ -9776,57 +9779,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"traceur": {
|
|
||||||
"version": "0.0.87",
|
|
||||||
"dependencies": {
|
|
||||||
"commander": {
|
|
||||||
"version": "2.6.0"
|
|
||||||
},
|
|
||||||
"glob": {
|
|
||||||
"version": "4.3.5",
|
|
||||||
"dependencies": {
|
|
||||||
"inflight": {
|
|
||||||
"version": "1.0.4",
|
|
||||||
"dependencies": {
|
|
||||||
"wrappy": {
|
|
||||||
"version": "1.0.1"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"inherits": {
|
|
||||||
"version": "2.0.1"
|
|
||||||
},
|
|
||||||
"once": {
|
|
||||||
"version": "1.3.2",
|
|
||||||
"dependencies": {
|
|
||||||
"wrappy": {
|
|
||||||
"version": "1.0.1"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"rsvp": {
|
|
||||||
"version": "3.0.18"
|
|
||||||
},
|
|
||||||
"semver": {
|
|
||||||
"version": "2.3.2"
|
|
||||||
},
|
|
||||||
"source-map-support": {
|
|
||||||
"version": "0.2.10",
|
|
||||||
"dependencies": {
|
|
||||||
"source-map": {
|
|
||||||
"version": "0.1.32",
|
|
||||||
"dependencies": {
|
|
||||||
"amdefine": {
|
|
||||||
"version": "0.1.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ts2dart": {
|
"ts2dart": {
|
||||||
"version": "0.7.4",
|
"version": "0.7.4",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
@ -10509,5 +10461,5 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"name": "angular",
|
"name": "angular",
|
||||||
"version": "2.0.0-alpha.36"
|
"version": "2.0.0-alpha.37"
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "angular",
|
"name": "angular",
|
||||||
"version": "2.0.0-alpha.36",
|
"version": "2.0.0-alpha.37",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"angular": {
|
"angular": {
|
||||||
"version": "1.3.5",
|
"version": "1.3.5",
|
||||||
|
@ -4633,6 +4633,11 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"es6-shim": {
|
||||||
|
"version": "0.33.3",
|
||||||
|
"from": "es6-shim@*",
|
||||||
|
"resolved": "https://registry.npmjs.org/es6-shim/-/es6-shim-0.33.3.tgz"
|
||||||
|
},
|
||||||
"event-stream": {
|
"event-stream": {
|
||||||
"version": "3.3.1",
|
"version": "3.3.1",
|
||||||
"from": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.1.tgz",
|
"from": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.1.tgz",
|
||||||
|
@ -15112,83 +15117,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"traceur": {
|
|
||||||
"version": "0.0.87",
|
|
||||||
"from": "https://registry.npmjs.org/traceur/-/traceur-0.0.87.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/traceur/-/traceur-0.0.87.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"commander": {
|
|
||||||
"version": "2.6.0",
|
|
||||||
"from": "https://registry.npmjs.org/commander/-/commander-2.6.0.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/commander/-/commander-2.6.0.tgz"
|
|
||||||
},
|
|
||||||
"glob": {
|
|
||||||
"version": "4.3.5",
|
|
||||||
"from": "https://registry.npmjs.org/glob/-/glob-4.3.5.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/glob/-/glob-4.3.5.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"inflight": {
|
|
||||||
"version": "1.0.4",
|
|
||||||
"from": "https://registry.npmjs.org/inflight/-/inflight-1.0.4.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.4.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"wrappy": {
|
|
||||||
"version": "1.0.1",
|
|
||||||
"from": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"inherits": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"from": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz"
|
|
||||||
},
|
|
||||||
"once": {
|
|
||||||
"version": "1.3.2",
|
|
||||||
"from": "https://registry.npmjs.org/once/-/once-1.3.2.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/once/-/once-1.3.2.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"wrappy": {
|
|
||||||
"version": "1.0.1",
|
|
||||||
"from": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"rsvp": {
|
|
||||||
"version": "3.0.18",
|
|
||||||
"from": "https://registry.npmjs.org/rsvp/-/rsvp-3.0.18.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/rsvp/-/rsvp-3.0.18.tgz"
|
|
||||||
},
|
|
||||||
"semver": {
|
|
||||||
"version": "2.3.2",
|
|
||||||
"from": "https://registry.npmjs.org/semver/-/semver-2.3.2.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/semver/-/semver-2.3.2.tgz"
|
|
||||||
},
|
|
||||||
"source-map-support": {
|
|
||||||
"version": "0.2.10",
|
|
||||||
"from": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.2.10.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.2.10.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"source-map": {
|
|
||||||
"version": "0.1.32",
|
|
||||||
"from": "https://registry.npmjs.org/source-map/-/source-map-0.1.32.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.1.32.tgz",
|
|
||||||
"dependencies": {
|
|
||||||
"amdefine": {
|
|
||||||
"version": "0.1.0",
|
|
||||||
"from": "https://registry.npmjs.org/amdefine/-/amdefine-0.1.0.tgz",
|
|
||||||
"resolved": "https://registry.npmjs.org/amdefine/-/amdefine-0.1.0.tgz"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ts2dart": {
|
"ts2dart": {
|
||||||
"version": "0.7.4",
|
"version": "0.7.4",
|
||||||
"from": "https://registry.npmjs.org/ts2dart/-/ts2dart-0.7.4.tgz",
|
"from": "https://registry.npmjs.org/ts2dart/-/ts2dart-0.7.4.tgz",
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"reflect-metadata": "0.1.1",
|
"reflect-metadata": "0.1.1",
|
||||||
"rx": "2.5.1",
|
"rx": "2.5.1",
|
||||||
"traceur": "0.0.87",
|
|
||||||
"zone.js": "0.5.4"
|
"zone.js": "0.5.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
@ -57,6 +56,7 @@
|
||||||
"del": "~1",
|
"del": "~1",
|
||||||
"dgeni": "^0.4.1",
|
"dgeni": "^0.4.1",
|
||||||
"dgeni-packages": "^0.10.11",
|
"dgeni-packages": "^0.10.11",
|
||||||
|
"es6-shim": "^0.33.3",
|
||||||
"event-stream": "^3.1.5",
|
"event-stream": "^3.1.5",
|
||||||
"firefox-profile": "^0.3.4",
|
"firefox-profile": "^0.3.4",
|
||||||
"fs-extra": "^0.18.0",
|
"fs-extra": "^0.18.0",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<script src="zone-microtask.js" type="text/javascript"></script>
|
<script src="zone-microtask.js" type="text/javascript"></script>
|
||||||
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
||||||
<script src="traceur-runtime.js" type="text/javascript"></script>
|
<script src="es6-shim.js" type="text/javascript"></script>
|
||||||
<script src="system.src.js" type="text/javascript"></script>
|
<script src="system.src.js" type="text/javascript"></script>
|
||||||
<script src="Reflect.js" type="text/javascript"></script>
|
<script src="Reflect.js" type="text/javascript"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<script src="zone-microtask.js" type="text/javascript"></script>
|
<script src="zone-microtask.js" type="text/javascript"></script>
|
||||||
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
||||||
<script src="url_params_to_form.js" type="text/javascript"></script>
|
<script src="url_params_to_form.js" type="text/javascript"></script>
|
||||||
<script src="traceur-runtime.js" type="text/javascript"></script>
|
<script src="es6-shim.js" type="text/javascript"></script>
|
||||||
<script src="system.src.js" type="text/javascript"></script>
|
<script src="system.src.js" type="text/javascript"></script>
|
||||||
<script src="Reflect.js" type="text/javascript"></script>
|
<script src="Reflect.js" type="text/javascript"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
<script src="long-stack-trace-zone.js" type="text/javascript"></script>
|
||||||
<script src="angular.js" type="text/javascript"></script>
|
<script src="angular.js" type="text/javascript"></script>
|
||||||
<script src="url_params_to_form.js" type="text/javascript"></script>
|
<script src="url_params_to_form.js" type="text/javascript"></script>
|
||||||
<script src="traceur-runtime.js" type="text/javascript"></script>
|
<script src="es6-shim.js" type="text/javascript"></script>
|
||||||
<script src="system.src.js" type="text/javascript"></script>
|
<script src="system.src.js" type="text/javascript"></script>
|
||||||
<script src="Reflect.js" type="text/javascript"></script>
|
<script src="Reflect.js" type="text/javascript"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
importScripts("zone-microtask.js", "long-stack-trace-zone.js", "traceur-runtime.js",
|
importScripts("zone-microtask.js", "long-stack-trace-zone.js", "es6-shim.js", "system.src.js",
|
||||||
"system.src.js", "Reflect.js");
|
"Reflect.js");
|
||||||
|
|
|
@ -5,7 +5,6 @@ var htmlReplace = require('../html-replace');
|
||||||
var jsReplace = require('../js-replace');
|
var jsReplace = require('../js-replace');
|
||||||
var path = require('path');
|
var path = require('path');
|
||||||
var stew = require('broccoli-stew');
|
var stew = require('broccoli-stew');
|
||||||
var traceur = require('traceur');
|
|
||||||
|
|
||||||
import compileWithTypescript from '../broccoli-typescript';
|
import compileWithTypescript from '../broccoli-typescript';
|
||||||
import destCopy from '../broccoli-dest-copy';
|
import destCopy from '../broccoli-dest-copy';
|
||||||
|
@ -143,7 +142,7 @@ module.exports = function makeBrowserTree(options, destinationPath) {
|
||||||
'node_modules/rx/dist/rx.js',
|
'node_modules/rx/dist/rx.js',
|
||||||
'node_modules/base64-js/lib/b64.js',
|
'node_modules/base64-js/lib/b64.js',
|
||||||
'node_modules/reflect-metadata/Reflect.js',
|
'node_modules/reflect-metadata/Reflect.js',
|
||||||
path.relative(projectRootDir, traceur.RUNTIME_PATH)
|
'node_modules/es6-shim/es6-shim.js'
|
||||||
]
|
]
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
|
|
@ -5,12 +5,11 @@ var insert = require('gulp-insert');
|
||||||
var fs = require('fs-extra');
|
var fs = require('fs-extra');
|
||||||
var browserify = require('browserify');
|
var browserify = require('browserify');
|
||||||
var path = require('path');
|
var path = require('path');
|
||||||
|
var Builder = require('systemjs-builder');
|
||||||
|
|
||||||
module.exports.bundle = function(buildConfig, moduleName, outputFile, outputConfig,
|
module.exports.bundle = function(buildConfig, moduleName, outputFile, outputConfig,
|
||||||
sfx) {
|
sfx) {
|
||||||
var sfx = sfx || false;
|
var sfx = sfx || false;
|
||||||
// loading it earlier interfers with custom traceur.
|
|
||||||
var Builder = require('systemjs-builder');
|
|
||||||
var builder = new Builder();
|
var builder = new Builder();
|
||||||
builder.config(buildConfig);
|
builder.config(buildConfig);
|
||||||
if (sfx) {
|
if (sfx) {
|
||||||
|
|
|
@ -3,8 +3,7 @@
|
||||||
var glob = require('glob');
|
var glob = require('glob');
|
||||||
var JasmineRunner = require('jasmine');
|
var JasmineRunner = require('jasmine');
|
||||||
var path = require('path');
|
var path = require('path');
|
||||||
// Require traceur to exposes $traceurRuntime on global context so that CJS files can run
|
require('es6-shim/es6-shim.js');
|
||||||
require('traceur/bin/traceur-runtime.js');
|
|
||||||
require('reflect-metadata/Reflect');
|
require('reflect-metadata/Reflect');
|
||||||
|
|
||||||
var jrunner = new JasmineRunner();
|
var jrunner = new JasmineRunner();
|
||||||
|
@ -23,19 +22,14 @@ if (globsIndex < 0) {
|
||||||
args = process.argv.slice(globsIndex + 1);
|
args = process.argv.slice(globsIndex + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
var specFiles = args.
|
var specFiles = args.map(function(globstr) { return glob.sync(globstr); })
|
||||||
map(function(globstr) { return glob.sync(globstr); }).
|
.reduce(function(specFiles, paths) { return specFiles.concat(paths); }, []);
|
||||||
reduce(function(specFiles, paths) { return specFiles.concat(paths); }, []);
|
|
||||||
|
|
||||||
jasmine.DEFAULT_TIMEOUT_INTERVAL = 1000;
|
jasmine.DEFAULT_TIMEOUT_INTERVAL = 1000;
|
||||||
|
|
||||||
jrunner.configureDefaultReporter({
|
jrunner.configureDefaultReporter({showColors: process.argv.indexOf('--no-color') === -1});
|
||||||
showColors: process.argv.indexOf('--no-color') === -1
|
|
||||||
});
|
|
||||||
|
|
||||||
jrunner.onComplete(function(passed) {
|
jrunner.onComplete(function(passed) { process.exit(passed ? 0 : 1); });
|
||||||
process.exit(passed ? 0 : 1);
|
|
||||||
});
|
|
||||||
jrunner.projectBaseDir = path.resolve(__dirname, '../../');
|
jrunner.projectBaseDir = path.resolve(__dirname, '../../');
|
||||||
jrunner.specDir = '';
|
jrunner.specDir = '';
|
||||||
jrunner.addSpecFiles(specFiles);
|
jrunner.addSpecFiles(specFiles);
|
Loading…
Reference in New Issue