- Fixup server script errors - f59aa40
- fix bad link for thorax seed/example repo - 6e4b301
- fix several minor spelling typos - 990002f
-
Remove path.relative fork - ad98c29
-
Cleanup loadResource error message - a3e4ad2
-
Fix callback on missing static file - 12eb8e5
-
Always define a module name - 6b7dcd2
-
Include additional info for scope order error - cce73f2
- Fixed map error under node 0.10
- Fixed stylus includes when overriding files in nested mixins
-
Update stylus to 0.36.1
-
Fixed root handling when overriding files in nested mixins
-
Fixed naming of overriden handlebars templates
-
Removed
Library.resolvePath
.Library.mapFile
should be used instead
- Fix mixin attribute propagation
- Ensure that all mixins are iterated over when adding to module
- Update uglify to 2.3
-
config
method has been removedThis has been replaced with the
config(config)
event which is emitted on the lumbar event instance after any changes to the config. -
Fixed error seen when mixins with child mixins where incorrectly included multiple times.
-
Refactor state machine and utils
- Fix error with ./ mixin in stylus
- Remove duplicate library declarations
- Allow library loading on CLI via
--library=name
- Allow CLI output named build or watch without requiring path components
- Allow library specification in template lookup
Compatibility Notes:
- If multiple watch or build commands are specified on the CLI the action will no longer be the last action specified. This could lead to unexpected behavior for improperly formed CLI commands.
- Hack around bower config issue when passing config files on CLI
-
Add bower namespace support through the
bower
resource attribute.Resources can no reference specific bower packages by name without needing to know where the bower path is.
-
Automatically load lumbar libraries that are in the bower components directory.
-
Use global config for template auto include
-
Update to Handlebars 1.0.12 / 1.0.0
-
Update minimum node version to 0.8
- Update stylus-images dependency
-
Lock down code generating library versions
-
#77 - Fix watch tracking if initial build fails
-
Allow server mode handlebars options
-
#88 - Implement global workers limit
-
Allow mixins to specify handlebars known helpers.
This moves the known helpers declaration from
templates.precompile.knownHelpers
totemplate.knownHelpers
. The older path is still available but does not support mixins.
-
Fix template linking for library modules
-
Output templates prior to their referencing file
-
Use
library
rather thancontainer
for fully qualified mixin lookup -
Allow plugins in Grunt task (@stehag)
-
Add verbose logging options
-
Rename root mixins to libraries.
Library import declarations have been changed from
mixins
tolibraries
and are otherwise identical. Likewise, resource library references have been changed frommixin
tolibrary
.
- Allow uglify config via
uglify
project config option.
- Implement server-scripts plugin
- Fix stylus execution outside of the lumbar directory
- Add overrides false flag to prevent output of particular resources from mixins
- Added
lumbar
grunt task
Changes:
-
Break stylus execution into worker processes
This change dropped build times across the board, with a large build that was taking 20 seconds dropping to 7 seconds. This breaks existing stylus plugins who must now be defined in worker files which may then be required into the worker process. Ex:
resource.plugins.push({
plugin: __dirname + '/stylus-config-worker',
data: config
});
- Support source map output to alternate locations
Changes:
- Fix bug while watching template files.
Changes:
- Cleanup override handling in stylus templates
- Allow template hash references to pull from specific mixins
- Fix stylus mixin compilation under combined compile
- Allow for nested mixin definition
Changes:
-
Add
depends
field to module map for lumbar loader module dependencies -
Fix source map comment output
-
Source map parsing performance improvements
-
Run uglify in parallel worker process(es)
Dramatically decreased processing time for large projects on multi-core machines.
Changes:
- Fix handling of styleRoot in mixins.
Changes:
-
Added support for source maps
-
Update mixin handling for namespaces
This allows different mixins to define mixins with the same name. Consumers can differentiate between the mixins via the
library
attribute on the mixin reference. i.e."mixins": [ {"name": "test", "library": "phoenix-build"} ]
All mixin projects must now define a name field so they may be referenced in this manner.
-
Fix incorrect configuration load when using watch mode.
-
Fix watch cleanup on file removal.
Changes:
-
Filter duplicate files in the same module
This behavior may be disabled on the resource level via the
"duplicate": true
attribute or at the application level with the"filterDuplicates": false
top level attribute. -
Files added through pattern mapping and auto-includes no longer require a config change to watch for changes.
-
Allow for disabling of all alliases with
"aliases": false
-
Fix CoffeeScript plugin (@jasonwebster)
Changes:
-
Implement source warning framework
-
Update to Uglify 2.2
NPM will refuse to install this under 0.8 and lower due to an upstream dependency so this is now optional.
-
Fix filtering of generated resources
Changes:
-
Add support for mixin file references via. mixin resource attribute.
{"src": "lumbar-loader-backbone.js", "mixin": "lumbar-loader"},
Mixins must define a name value in the mixin config file to utilize this feature.
-
Fix template auto-include in mixin contexts
-
Fix execution error in coffeescript plugin (needs unit tests)
Changes:
-
Add
template.root
property for template prefix stripping. -
Removed precompiled template template.
Moving forward template templates should use
{{handlebarsCall}}
to differentiate between precompiled and client compiled mode.
Changes:
-
Watch support for mixin config. Changes to mixin config files will now rebuild the project when in watch mode.
-
Allow file config independent rebuilds
Adds isPrimary flag to the file config. When true this will rebuild all configs for a given mode. When false will ignore changes to the inputs when undefined will continue the default behavior of separate rebuilds.
-
Optimize stylus builds when using multiple pixel densities.
This saves about 50% of the developer build time for mobile.walmart.com.
-
stylus-config plugin for sharing variables between stylus and javascript
-
Allow lumbar plugins to interact with the stylus compiler at runtime
Allows plugins to register callbacks on the stylus generator using the
plugins
field. This mechanism allows additional plugins and source modifications on stylus compilation steps. The stylus-config plugin provides an example of this API's usage. -
Optimize plugin execution loop
The plugin executor now enforces async execution of async callbacks. This may break plugins that incorrectly took advantage of non-contract synchronous behavior in the app.
-
Switch to cheerio for update-externals parsing
-
Improve various error messages
-
Watch package config files for changes
-
CLI: Allow multiple --module parameters
Changes:
- Allow specific modules to disable particular aliases.
Changes:
-
Improves EMFILE error handling.
-
Watch unit test library updates
Changes:
-
Separated handlebars processing from template includes
Handlebar templates may now be included in script array or the template lookup field. Templates in the lookup field are no longer required to be handlebars templates.
-
Template plugin now supports pattern matching includes.
Example mapping for thorax template structure:
"templates": { "auto-include": { "js/views/(.*)\\.(?:js|coffee)": [ "templates/$1.handlebars", "templates/$1-item.handlebars", "templates/$1-empty.handlebars" ] } }
-
Local module reference support
Module variables are now aliased internally meaning that a module with a top level name
Application
can access it's exported members by accessing theApplication
object at any point in time. Previously initialization logic was only able to access this through theexports
ormodule.exports
references.Note that for top level objects this is an alias so assigning to this variable will not update the external reference. The default template is configured to warn in the event that it detects this situation.
-
Scope aliases
It's now possible to define aliases globally via the scope.alias config object and locally by defining the alias object on specific modules. These alias will create local variable references to any javascript statement, allowing for minimization of frequently used references.
Example global aliases:
"scope": { "aliases": { "View": "Application.View", "Application": "Application" } }
-
Allow filtering of resources via not structures, i.e.
"platform": {"not": "web"}
and"packages": {"not": ["foo", "bar"]}
. -
Allow filtering of resources based on combined module or not via the
combined
attribute. Undefined for all modes, true for combined mode only, false for non-combined only. -
Significant rework of tests to focus more on unit testing with better edge case coverage
-
Fixed mixin modules implementation. Properly links to mixin files. Mixin modules may now be applied as mixins to other modules, have their own mixins, and be suppressed via false module value.
Changes:
-
Mixin support
-
Stylus useNib flag
UPDATE: As of beta 2 this is no longer a breaking change. Includes referencing nib directly will have this flag applied.
Updates nib include in stylus to utilize a named attribute. This was necessary to support mixins of the nib plugin. Update path for nib users is to remove the
nib
entry from the styles includes list and to add auseNib
attribute to the styles object set to true.Old:
"styles": { "includes": ["nib"] }
New:
"styles: { "useNib": true }
-
Scope
- Possible to define both a scope and template value.
-
API Changes
-
config.readConfig utility method
Helper method that strips out comments and other comments that causes the JSON parse to blow up. It's recommended that all interaction with lumbar config files use this helper method.
-
config.create factor method
Method used for creating a config object from a javascript key-value object rather than directly from a file.
-
Moved config.fileList and config.filterResource to static lumbar.build object
-
Created new loadMixin and loadConfig plugin points. Plugins that need to perform mixin-specific behavior should implement these methods.
-