Skip to content

Unable to create library #11014

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

Closed
guysenpai opened this issue May 25, 2018 · 4 comments
Closed

Unable to create library #11014

guysenpai opened this issue May 25, 2018 · 4 comments

Comments

@guysenpai
Copy link

Versions

     _                      _                 ____ _     ___
    / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
   / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
  / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
 /_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
                |___/


Angular CLI: 6.0.3
Node: 9.11.1
OS: darwin x64
Angular: 6.0.3
... animations, cli, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router, service-worker

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.6.3
@angular-devkit/build-angular     0.6.3
@angular-devkit/build-optimizer   0.6.3
@angular-devkit/core              0.6.3
@angular-devkit/schematics        0.6.3
@angular/cdk                      6.1.0
@angular/flex-layout              6.0.0-beta.15
@angular/material                 6.1.0
@angular/pwa                      0.6.3
@ngtools/webpack                  6.0.3
@schematics/angular               0.6.3
@schematics/update                0.6.3
rxjs                              6.2.0
typescript                        2.7.2
webpack                           4.8.3

Repro steps

  • Step 1
  • Step 2
  • Step 3

Observed behavior

 ng generate library modulo-theme --prefix mod
Unexpected token } in JSON at position 581
error Command failed with exit code 1.

Desired behavior

I want to generate a library

Mention any other details that might be useful (optional)

@hamoom
Copy link

hamoom commented May 25, 2018

having a similar issue

ng generate library my-header
Unexpected token ] in JSON at position 863

@hamoom
Copy link

hamoom commented May 25, 2018

I had this trailing comma in my styles in my angular.json file. it was causing the error.

            "styles": [
              "src/styles.css",
            ],

@hansl
Copy link
Contributor

hansl commented Jun 7, 2018

We have a fix for this. In the meantime this is a dupe of #10757. Short answer; it's a bug and trailing commas should be allowed in angular.json (it's a JSON 5 file).

@hansl hansl closed this as completed Jun 7, 2018
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants