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

Add builder generation on install/add #15

Open
kaltepeter opened this issue Oct 28, 2020 · 3 comments
Open

Add builder generation on install/add #15

kaltepeter opened this issue Oct 28, 2020 · 3 comments
Assignees

Comments

@kaltepeter
Copy link
Collaborator

Support installing or adding with --project flag to generate build-icons config in angular.json

Would be nice if schema matched the three possible conversionTypes.

Relates to #9

Sample for constants:

     "update-icons": {
          "builder": "@angular-extensions/svg-icons-builder:svg-icons-builder",
          "options": {
            "conversionType": "constants",
            "srcFiles": ["./projects/dinosaur-icons/icons/**/*.svg"],
            "outputDirectory": "./projects/dinosaur-icons/icons",
            "interfaceName": "DinosaurIcon",
            "typeName": "dinosaurIcon",
            "prefix": "dinosaurIcon",
            "modelFileName": "dinosaur-icons",
            "svgoConfig": {
              "plugins": [
                {
                  "cleanupAttrs": true
                }
              ]
            },
            "additionalModelFile": "./projects/dinosaur-icons/src/lib",
            "compileSources": true
          }
        },
@kaltepeter
Copy link
Collaborator Author

@kreuzerk thoughts on this?

@nivekcode
Copy link
Member

Definitely. This would be very nice. It would be nice that the ng-add command asks for the various properties. I am not yet sure how we can make this conditional - so for example that ng-add asks you for the conversionType. Based on that it should then aks for the correct options and then automatically configure the builder in the angular.json

@kaltepeter
Copy link
Collaborator Author

Yeah, I am not 100% certain either. It seems do-able to conditionally drive the builder called.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants