Skip to content

Commit

Permalink
chore: clean up legacy code
Browse files Browse the repository at this point in the history
closes #1172, #1173
  • Loading branch information
3cp committed Apr 12, 2020
1 parent 5da5355 commit 099469d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,8 @@ function configureEnvironment() {
.pipe(gulp.dest(project.paths.root));
}

var typescriptCompiler = typescriptCompiler || null;

function buildTypeScript() {
typescriptCompiler = ts.createProject('tsconfig.json', {
const typescriptCompiler = ts.createProject('tsconfig.json', {
typescript: require('typescript')
});

Expand All @@ -49,7 +47,7 @@ export default gulp.series(
export function buildPluginJavaScript(dest, format) {
// when format is missing, default is ESM as we turned off "modules": false in .babelrc.js
return function processPluginJavaScript() {
typescriptCompiler = ts.createProject('tsconfig.json', {
const typescriptCompiler = ts.createProject('tsconfig.json', {
typescript: require('typescript'),
module: format
});
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import { inject } from 'aurelia-dependency-injection';
import { Project, ProjectItem, CLIOptions, UI } from 'aurelia-cli';

var path = require('path');
// @if feat.babel
import path from 'path';
// @endif
// @if feat.typescript
import * as path from 'path';
// @endif

@inject(Project, CLIOptions, UI)
export default class ElementGenerator {
Expand Down

0 comments on commit 099469d

Please sign in to comment.