Skip to content

Angular module per each files source#113

Open
gugiserman wants to merge 1 commit intoericclemmons:masterfrom
gugiserman:feature/moduleFromFilesSource
Open

Angular module per each files source#113
gugiserman wants to merge 1 commit intoericclemmons:masterfrom
gugiserman:feature/moduleFromFilesSource

Conversation

@gugiserman
Copy link
Copy Markdown

E.g.: (two components in their own ng-module and a default module for the rest)

ngtemplates:
  files: [
    { cwd: 'src/components/',
      src: 'component/*.html', dest: 'build/components/component/component-template.js',
      module: 'component' },
    { cwd: 'src/components/',
      src: 'other-component/*.html', dest: 'build/components/other-component/other-component-template.js',
      module: 'other.component' },
    { cwd: 'src/templates/',
      src: '*.html', dest: 'build/templates/app-templates.js' },
  ]
  options: {
    module: 'app'
  }

Initial working implementation
@ericclemmons
Copy link
Copy Markdown
Owner

I'm amazed that tests still pass with this change! It must be due to Grunt's internal normalizing of files or whatever.

@gugiserman
Copy link
Copy Markdown
Author

Magic meme gif

@underscorebrody
Copy link
Copy Markdown
Collaborator

@gugiserman I'm not sure I agree that this doesn't justify a new test, given that it adds completely new functionality. Would you mind adding one?

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

Successfully merging this pull request may close these issues.

4 participants