Skip to content
This repository was archived by the owner on Dec 17, 2018. It is now read-only.

Commit bd34955

Browse files
committed
Merge branch 'tommueller-master' adds compodoc
2 parents 23cc50b + 04a5ac8 commit bd34955

File tree

7 files changed

+40
-2
lines changed

7 files changed

+40
-2
lines changed

README.md

+7
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,10 @@ Creates the project structure and a slew of files:
165165
|__package.json
166166
|__README.md
167167
|__tsconfig.json
168+
|__tsconfig.doc.json
169+
|__tsconfig.es5.json
170+
|__tsconfig.es2015.json
171+
|__tsconfig.test.json
168172
|__tslint.json
169173
```
170174

@@ -192,6 +196,9 @@ Creates the project structure and a slew of files:
192196
the library
193197
- `test.ts`: contains code needed to get the Angular test environment bootstrapped
194198
- `tsconfig.json`: the TypeScript configuration for the project
199+
- `tsconfig.*.json`: the TypeScript configuration for specific tasks (`doc` is for
200+
documentation generationg, `es5` & `es2015` are for builds, and `test` is for
201+
testing)
195202
- `tslint.json`: the linting rules for the project
196203
- `vendor.ts`: contains a list of dependencies that Angular needs loaded before the
197204
application is loaded

commands/initial/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ module.exports = (rootDir, ...args) => {
4242
{ destination: srcDir('index.ts'), name: 'src/index.ts' },
4343
{ destination: srcDir('test.js'), name: 'src/test.js', overwrite: true },
4444
{ name: 'tsconfig.json', overwrite: true },
45+
{ name: 'tsconfig.doc.json', overwrite: true },
4546
{ name: 'tsconfig.es2015.json', overwrite: true },
4647
{ name: 'tsconfig.es5.json', overwrite: true },
4748
{ name: 'tsconfig.test.json', overwrite: true },

commands/initial/templates/package.json

+4-2
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,16 @@
77
"es2015": "./{{ name }}.js",
88
"typings": "./{{ packageName }}.d.ts",
99
"scripts": {
10-
"build": "node ./tasks/build",
10+
"build": "node ./tasks/build && npm run compodoc",
1111
"g": "node ./node_modules/angular-librarian",
1212
"lint": "tslint ./src/**/*.ts",
1313
"postbuild": "rimraf build",
1414
"posttagVersion": "npm run build && npm publish dist",
1515
"prebuild": "rimraf dist out-tsc",
1616
"start": "webpack-dev-server --open --config ./webpack/webpack.dev.js",
1717
"tagVersion": "node ./tasks/tag-version",
18-
"test": "node ./tasks/test"
18+
"test": "node ./tasks/test",
19+
"compodoc": "compodoc src -p tsconfig.doc.json --disableInternal --disablePrivate"
1920
},
2021
"keywords": [],
2122
"author": "",
@@ -32,6 +33,7 @@
3233
},
3334
"devDependencies": {
3435
"@angular/compiler-cli": "^5.0.0",
36+
"@compodoc/compodoc": "^1.0.7",
3537
"@types/jasmine": "^2.0.0",
3638
"@types/node": "^8.0.0",
3739
"angular-librarian": "{{ librarianVersion }}",
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"angularCompilerOptions": {
3+
"strictMetadataEmit": true,
4+
"skipTemplateCodegen": true
5+
},
6+
"compilerOptions": {
7+
"baseUrl": "",
8+
"declaration": true,
9+
"emitDecoratorMetadata": true,
10+
"experimentalDecorators": true,
11+
"lib": ["es2015", "dom"],
12+
"mapRoot": "./",
13+
"module": "es2015",
14+
"moduleResolution": "node",
15+
"outDir": "./dist",
16+
"sourceMap": true,
17+
"target": "es5",
18+
"typeRoots": [
19+
"./node_modules/@types"
20+
]
21+
},
22+
"awesomeTypescriptLoaderOptions": {
23+
"forkChecker": true
24+
}
25+
}

commands/upgrade/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@ const updateFiles = () => {
128128
{ name: 'tsconfig.es5.json', overwrite: true },
129129
{ name: 'tsconfig.es2015.json', overwrite: true },
130130
{ name: 'tsconfig.json', overwrite: true },
131+
{ name: 'tsconfig.doc.json', overwrite: true },
131132
{ name: 'tsconfig.test.json', overwrite: true },
132133
{ name: 'tslint.json', overwrite: true },
133134
{ destination: srcDir('test.js'), name: 'src/test.js', overwrite: true },

test/initial.spec.js

+1
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,7 @@ tap.test('command: initial', (suite) => {
249249
{ destination: '/created/src/index.ts', name: 'src/index.ts' },
250250
{ destination: '/created/src/test.js', name: 'src/test.js', overwrite: true },
251251
{ name: 'tsconfig.json', overwrite: true },
252+
{ name: 'tsconfig.doc.json', overwrite: true },
252253
{ name: 'tsconfig.es2015.json', overwrite: true },
253254
{ name: 'tsconfig.es5.json', overwrite: true },
254255
{ name: 'tsconfig.test.json', overwrite: true },

test/upgrade.spec.js

+1
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,7 @@ tap.test('command: upgrade', (suite) => {
259259
{ name: 'tsconfig.es5.json', overwrite: true },
260260
{ name: 'tsconfig.es2015.json', overwrite: true },
261261
{ name: 'tsconfig.json', overwrite: true },
262+
{ name: 'tsconfig.doc.json', overwrite: true },
262263
{ name: 'tsconfig.test.json', overwrite: true },
263264
{ name: 'tslint.json', overwrite: true },
264265
{

0 commit comments

Comments
 (0)