Skip to content

Commit

Permalink
use --ESModuleInterop microsoft/TypeScript#19675
Browse files Browse the repository at this point in the history
  • Loading branch information
aluanhaddad committed Jan 19, 2018
1 parent a3be208 commit f443546
Show file tree
Hide file tree
Showing 17 changed files with 196 additions and 74 deletions.
2 changes: 2 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
{
"tslint.autoFixOnSave": true,
"editor.formatOnPaste": true,
"editor.formatOnType": true,
"editor.formatOnSave": true
}
102 changes: 70 additions & 32 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
},
"license": "MIT",
"dependencies": {
"@types/bluebird": "^3.5.18",
"@types/bluebird": "^3.5.19",
"@types/chalk": "^2.2.0",
"@types/deep-equal": "^1.0.1",
"@types/minimist": "1.2.0",
Expand All @@ -41,17 +41,17 @@
"mz": "^2.7.0",
"request": "^2.83.0",
"request-promise": "^4.2.2",
"tslib": "^1.8.0"
"tslib": "^1.9.0"
},
"devDependencies": {
"@types/tape": "^4.2.31",
"jspm": "^0.17.0-beta.47",
"rimraf": "2.6.2",
"source-map-support": "^0.5.0",
"source-map-support": "^0.5.2",
"tape": "^4.8.0",
"ts-node": "^3.3.0",
"tslint": "^5.8.0",
"typescript": "next"
"tslint": "^5.9.1",
"typescript": "^2.7.0-dev.20180119"
},
"keywords": [
"aurelia",
Expand Down
4 changes: 2 additions & 2 deletions src/aquire-declaration.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import mz = require('mz');
import requestPromise = require('request-promise');
import mz from 'mz';
import requestPromise from 'request-promise';

import ensureDir from './ensure-dir';

Expand Down
2 changes: 1 addition & 1 deletion src/ensure-dir.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mz = require('mz');
import mz from 'mz';
const {fs} = mz;

export default async function ensureDir(path: string) {
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import chalk from 'chalk';

import thisPackage = require('../package.json');
import thisPackage from '../package.json';

import './polyfills/enhance';

Expand Down
6 changes: 6 additions & 0 deletions src/install-options.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export default interface InstallOptions {
projectDir: string;
framework: string;
dest: string;
explicitIndex: boolean;
}
14 changes: 4 additions & 10 deletions src/install.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,14 @@
import deepEqual = require('deep-equal');
import mz = require('mz');
import path = require('path');
import deepEqual from 'deep-equal';
import mz from 'mz';
import path from 'path';

import downloadDeclaration from './aquire-declaration';
import ensureDir from './ensure-dir';
import loadJspmConfiguration from './load-jspm-configuration';
import InstallOptions from './install-options';

const {fs} = mz;

export interface InstallOptions {
projectDir: string;
framework: string;
dest: string;
explicitIndex: boolean;
}

export default async function install({projectDir, framework, dest, explicitIndex}: InstallOptions) {
const baseUrl = await fs.realpath(projectDir);
let successSummary = '';
Expand Down
4 changes: 2 additions & 2 deletions src/load-jspm-configuration.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import mz = require('mz');
import path = require('path');
import mz from 'mz';
import path from 'path';

import extractJspmConfig from './extract-jspm-config';

Expand Down
4 changes: 2 additions & 2 deletions src/parse-args.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import minimist = require('minimist');
import minimist from 'minimist';

import {InstallOptions} from './install';
import InstallOptions from './install-options';

export default function parseArgs() {
const {_: [command], projectDir, framework, dest, explicitIndex, version, help} = minimist(process.argv.slice(2), {
Expand Down
2 changes: 1 addition & 1 deletion test/testapp/jspm.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ SystemJS.config({
"fs": "npm:jspm-nodelibs-fs@0.2.0",
"os": "npm:jspm-nodelibs-os@0.2.0",
"path": "npm:jspm-nodelibs-path@0.2.0",
"process": "npm:jspm-nodelibs-process@0.2.0",
"process": "github:jspm/nodelibs-process@0.2.0-alpha",
"stream": "npm:jspm-nodelibs-stream@0.2.0",
"string_decoder": "npm:jspm-nodelibs-string_decoder@0.2.0",
"util": "npm:jspm-nodelibs-util@0.2.0",
Expand Down
2 changes: 1 addition & 1 deletion test/testapp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"fs": "npm:jspm-nodelibs-fs@^0.2.0",
"os": "npm:jspm-nodelibs-os@^0.2.0",
"path": "npm:jspm-nodelibs-path@^0.2.0",
"process": "npm:jspm-nodelibs-process@^0.2.0",
"process": "github:jspm/nodelibs-process@^0.2.0-alpha",
"stream": "npm:jspm-nodelibs-stream@^0.2.0",
"string_decoder": "npm:jspm-nodelibs-string_decoder@^0.2.0",
"util": "npm:jspm-nodelibs-util@^0.2.0",
Expand Down
26 changes: 13 additions & 13 deletions test/testapp/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"extends": "./tsconfig.paths.json",
"compilerOptions": {
"module": "system",
"target": "es6",
"sourceMap": true,
"allowSyntheticDefaultImports": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true
},
"exclude": [
"node_modules",
"jspm_packages"
]
"extends": "./tsconfig.paths.json",
"compilerOptions": {
"module": "system",
"target": "es6",
"sourceMap": true,
"allowSyntheticDefaultImports": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true
},
"exclude": [
"node_modules",
"jspm_packages"
]
}
Loading

0 comments on commit f443546

Please sign in to comment.