[BUG] Incompatible with Angular 8
See original GitHub issueOverview of the issue
compodoc 1.1.10 is incompatible with Angular 8.
Documentation created without errors but the source code isn’t parsed probably because the routing isn’t taken into account. FYI, Angular 8 introduced a new directory structure (ex: tsconfig.app.json moved from inside /src to / by default)
Works with Angular 7:
npm -g install @angular/cli@7.3.9 ng new angular7-test --routing --style=scss cd angular7-test npx compodoc -p src/tsconfig.app.json
1.1.10
TypeScript version used by Compodoc : 2.9.1
TypeScript version of current project : 3.2.2
Node.js version : v12.7.0
Operating system : Windows 10
[09:14:23] No configuration file found, switching to CLI flags.
[09:14:23] Using tsconfig file : C:\Work\Playground\angular7-test\src\tsconfig.app.json
[09:14:23] Including : C:\Work\Playground\angular7-test\src\browserslist
[09:14:23] Including : C:\Work\Playground\angular7-test\src\favicon.ico
[09:14:23] Including : C:\Work\Playground\angular7-test\src\index.html
[09:14:23] Including : C:\Work\Playground\angular7-test\src\karma.conf.js
[09:14:23] Including : C:\Work\Playground\angular7-test\src\main.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\polyfills.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\styles.scss
[09:14:23] Excluding : C:\Work\Playground\angular7-test\src\test.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\tsconfig.app.json
[09:14:23] Including : C:\Work\Playground\angular7-test\src\tsconfig.spec.json
[09:14:23] Including : C:\Work\Playground\angular7-test\src\tslint.json
[09:14:23] Including : C:\Work\Playground\angular7-test\src\app\app.component.html
[09:14:23] Including : C:\Work\Playground\angular7-test\src\app\app.component.scss
[09:14:23] Including : C:\Work\Playground\angular7-test\src\app\app-routing.module.ts
[09:14:23] Ignoring : C:\Work\Playground\angular7-test\src\app\app.component.spec.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\app\app.component.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\app\app.module.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\assets\.gitkeep
[09:14:23] Including : C:\Work\Playground\angular7-test\src\environments\environment.prod.ts
[09:14:23] Including : C:\Work\Playground\angular7-test\src\environments\environment.ts
[09:14:23] Searching package.json file
[09:14:23] package.json file found
[09:14:23] Processing package.json dependencies
[09:14:23] Searching README.md, CHANGELOG.md, CONTRIBUTING.md, LICENSE.md, TODO.md files
[09:14:23] README.md file found
[09:14:23] Error during C:\Work\Playground\angular7-test\CHANGELOG read
[09:14:23] Continuing without CHANGELOG.md file
[09:14:23] Error during C:\Work\Playground\angular7-test\CONTRIBUTING read
[09:14:23] Continuing without CONTRIBUTING.md file
[09:14:23] Error during C:\Work\Playground\angular7-test\LICENSE read
[09:14:23] Continuing without LICENSE.md file
[09:14:23] Error during C:\Work\Playground\angular7-test\TODO read
[09:14:23] Continuing without TODO.md file
[09:14:23] Get dependencies data
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/main.ts
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/polyfills.ts
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/app/app-routing.module.ts
[09:14:23] Analysing routes definitions and clean them if necessary
[09:14:23] found : AppRoutingModule
[09:14:23] : - imports:
[09:14:23] : - RouterModule
[09:14:23] : - exports:
[09:14:23] : - RouterModule
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/app/app.component.ts
[09:14:23] found : AppComponent
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/app/app.module.ts
[09:14:23] found : AppModule
[09:14:23] : - imports:
[09:14:23] : - BrowserModule
[09:14:23] : - AppRoutingModule
[09:14:23] : - declarations:
[09:14:23] : - AppComponent
[09:14:23] : - bootstrap:
[09:14:23] : - AppComponent
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/environments/environment.prod.ts
[09:14:23] parsing : C:/Work/Playground/angular7-test/src/environments/environment.ts
[09:14:23] -------------------
[09:14:23] Project statistics
[09:14:23] - files : 18
[09:14:23] - module : 2
[09:14:23] - component : 1
[09:14:23] -------------------
[09:14:23] Prepare components
[09:14:23] AppComponent has a templateUrl, include it
[09:14:23] AppComponent has styleUrls, include them
[09:14:23] Prepare modules
[09:14:23] Process routes
[09:14:23] Routes index generated
[09:14:23] Prepare miscellaneous
[09:14:23] Process documentation coverage report
[09:14:23] Process main graph
(node:7040) V8: C:\Users\hewatp\AppData\Roaming\npm\node_modules\@compodoc\compodoc\node_modules\viz.js\viz.js:33 Invalid asm.js: Function definition doesn't match use
[09:14:23] Process module graph : AppModule
[09:14:23] Process module graph : AppRoutingModule
[09:14:23] Process pages
[09:14:23] Process page : AppComponent
[09:14:24] Process page : AppModule
[09:14:24] Process page : AppRoutingModule
[09:14:24] Process page : coverage
[09:14:24] Process page : dependencies
[09:14:24] Process page : index
[09:14:24] Process page : modules
[09:14:24] Process page : overview
[09:14:24] Process page : routes
[09:14:24] Process page : variables
[09:14:24] Process menu...
[09:14:24] Copy main resources
[09:14:24] Documentation generated in ./documentation/ in 1.341 seconds using gitbook theme
Content of src/tsconfig.app.json (generated using @angular/cli@7.3.9)
{
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/app",
"types": []
},
"exclude": [
"test.ts",
"**/*.spec.ts"
]
}
Fails with Angular 8:
npm -g remove @angular/cli npm -g install @angular/cli@8.2.1 ng new angular8-test --routing --style=scss cd angular8-test npx compodoc -p tsconfig.app.json
1.1.10
TypeScript version used by Compodoc : 2.9.1
TypeScript version of current project : 3.5.3
Node.js version : v12.7.0
Operating system : Windows 10
[09:38:48] No configuration file found, switching to CLI flags.
[09:38:48] Using tsconfig file : C:\Work\Playground\angular8-test\tsconfig.app.json
[09:38:48] Searching package.json file
[09:38:48] package.json file found
[09:38:48] Processing package.json dependencies
[09:38:48] Searching README.md, CHANGELOG.md, CONTRIBUTING.md, LICENSE.md, TODO.md files
[09:38:48] README.md file found
[09:38:48] Error during C:\Work\Playground\angular8-test\CHANGELOG read
[09:38:48] Continuing without CHANGELOG.md file
[09:38:48] Error during C:\Work\Playground\angular8-test\CONTRIBUTING read
[09:38:48] Continuing without CONTRIBUTING.md file
[09:38:48] Error during C:\Work\Playground\angular8-test\LICENSE read
[09:38:48] Continuing without LICENSE.md file
[09:38:48] Error during C:\Work\Playground\angular8-test\TODO read
[09:38:48] Continuing without TODO.md file
[09:38:48] Get dependencies data
[09:38:48] parsing : C:/Work/Playground/angular8-test/src/main.ts
[09:38:48] parsing : C:/Work/Playground/angular8-test/src/polyfills.ts
[09:38:48] -------------------
[09:38:48] Project statistics
[09:38:48] -------------------
[09:38:48] Prepare components
[09:38:48] Prepare modules
[09:38:48] Process documentation coverage report
[09:38:48] Process main graph
(node:14016) V8: C:\Users\hewatp\AppData\Roaming\npm\node_modules\@compodoc\compodoc\node_modules\viz.js\viz.js:33 Invalid asm.js: Function definition doesn't match use
[09:38:48] Process pages
[09:38:48] Process page : coverage
[09:38:48] Process page : dependencies
[09:38:48] Process page : index
[09:38:48] Process page : modules
[09:38:48] Process page : overview
[09:38:48] Process menu...
[09:38:48] Copy main resources
[09:38:48] Documentation generated in ./documentation/ in 0.951 seconds using gitbook theme
Content of tsconfig.app.json (generated using @angular/cli@8.2.1)
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "./out-tsc/app",
"types": []
},
"files": [
"src/main.ts",
"src/polyfills.ts"
],
"include": [
"src/**/*.ts"
],
"exclude": [
"src/test.ts",
"src/**/*.spec.ts"
]
}
Related issues
Issue Analytics
- State:
- Created 4 years ago
- Reactions:9
- Comments:17 (2 by maintainers)
Top Results From Across the Web
Incompatible peer dependencies found - upgrading Angular ...
Package "@ngtools/webpack" has an incompatible peer dependency to "typescript" (requires ">=3.4 < 3.6", would install "3.7.5").
Read more >Upgrading Angular versions has to be the most frustrating ...
Upgrading from 12-13 to eventually 14. First problem: Package "@angular-eslint/schematics" has an incompatible peer dependency…
Read more >Update to Angular 11 Version - Angular Wiki
Package "codelyzer" has an incompatible peer dependency to ... The first step I did to fix the error is to run command with...
Read more >Upgrade Angular App to latest version - Medium
If you are still using older version of Angular like 8, ... devkit which are incompatible to latest version and hence Angular throws...
Read more >Template type checking - Angular
In strict mode, Angular uses checks that go beyond the version 8 type-checker. ... which would result in an error if their types...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
with angular 8, use
compodoc -p tsconfig.json -s
and everything is working, including routing1.1.11 is out, with ng 8 routing support