Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #203 playground module not found linting error #210

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions generators/app/playground.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,12 @@ const setupPlayground =
}
);

generator.fs.copy(
generator.templatePath('playground/tsconfig.json'),
generator.destinationPath('playground/tsconfig.json')
generator.fs.copyTpl(
generator.templatePath('playground/_tsconfig.json'),
generator.destinationPath('playground/tsconfig.json'),
{
props: generator.props
}
);

generator.fs.copy(
Expand Down
4 changes: 3 additions & 1 deletion generators/app/templates/_package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,10 @@
"docs:build": "compodoc -p tsconfig.json -n <%= props.libraryName.original %> -d docs --hideGenerator",
"docs:serve": "npm run docs:build -- -s",
"docs:watch": "npm run docs:build -- -s -w",
"lint": "tslint --type-check --project tsconfig.json src/**/*.ts",
"lint:lib": "tslint --type-check --project tsconfig.json",
"lint": "npm run lint:lib && npm run playground:lint",
"lite": "lite-server",
"playground:lint": "npm run build && tslint --type-check --project playground/tsconfig.json",
"playground:build": "tsc -p playground -w",
"playground": "concurrently \"npm run build:watch\" \"npm run playground:build\" \"npm run lite\"",
"test": "tsc && karma start"
Expand Down
10 changes: 8 additions & 2 deletions generators/app/templates/_tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@
"dom"
],
"skipLibCheck": true,
"types": []
}
"typeRoots": [
"node_modules/@types"
]
},
"exclude": [
"node_modules",
"playground"
]
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"compilerOptions": {
"baseUrl": ".",
"outDir": "../.playground",
"target": "es5",
"module": "commonjs",
Expand All @@ -9,6 +10,9 @@
"experimentalDecorators": true,
"lib": [ "es2015", "dom" ],
"noImplicitAny": true,
"suppressImplicitAnyIndexErrors": true
"suppressImplicitAnyIndexErrors": true,
"paths": {
"<%= props.libraryName.kebabCase %>": ["../dist/index.d.ts"]
}
}
}