Skip to content

Proposal: integrating efforts #49

Closed
@dsebastien

Description

@dsebastien

Hello,

I've seen @IgorMinar 's presentation of angular-cli & @pkozlowski-opensource talk about ES2015, modules, System, JSPM etc while at AngularConnect in London and found the idea of Angular CLI to be pretty similar to 2 small projects I have created recently:

Since @IgorMinar mentioned that community participation was welcomed, here I go! :)

I don't know how far you guys are willing to go with Angular CLI and how prescriptive you want to be, but maybe some ideas below would be worth discussing.

Here's an overview of my projects:

ModernWebDevBuild is based on Google's Web Starter Kit (heavily tweaked/enhanced) and can be used to:

  • transpile ES2015 to ES5 w/ sourcemaps
  • transpile TypeScript to ES5 w/ sourcemaps
  • transpile SASS to CSS w/ sourcemaps
  • check JS/TS code style & code quality (requires JSCS/JSHint/TSHint config files to be present)
  • serve the app with support for multi-device sync (using BrowserSync) and watch tasks that constantly do all the above without stopping when an error occurs (continuous flow for the developer with useful feedback)
  • generate production bundles for CSS/JS/HTML/images
  • serve the production build (without watch)

ModernWebDevBuild has minimal requirements regarding the project structure and the presence of some files, but I think this is positive as it provides a good starting point for larger projects.

There are some major features still missing such as testing integration, configurability & extensibility, but I think that it is already useful as is.

ModernWebDevGenerator is a Yeoman generator that integrates the use of ModernWebDevBuild (which is just one npm dep) and generates a working project starting point. It integrates some code organization/design guidelines for structuring the application components, pages, etc in a logical manner while considering componentization as first-class concept by regrouping all pieces of a given component together (e.g., component class, component styles, component tests, ...). Given that the build is flexible enough, it doesn't prevent users from reorganizing as they wish.

Both projects are pretty opinionated thus I suppose that there are choices in there that you wouldn't impose on your users (e.g., Gulp, SystemJS, JSPM, SASS, ...), but maybe the feature set and/or necessary extensibility could be integrated within Angular CLI and/or Angular Toolkit?

I think that:

  • having a recommended project structure & organization guidelines is beneficial at many levels
  • having live reloading with multi-device synchronization support is great
  • having continuous transpilation, code compilation/quality/style feedback (without breaking) is awesome for developer productivity
  • having a "standard" way of building projects (from dev to prod) is tremendously useful for larger projects and integration with CI & CD solutions
  • having an extension system to let the community cater for its own needs is a must (e.g., CSS copy by default and a SASS plugin for those who want that)

Most importantly, I think that having a Google-backed basis for all this, with enough anchor points for extensions would be awesome for larger projects requiring more than Plunker :)

By having this one central piece in the Angular "build puzzle", it might be easier to make related projects evolve in the good direction; for example for now TypeScript can look up modules in node_modules but is totally incapable of doing the same with jspm_packages, although that could be really nice.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions