Releases: anodynos/uRequire
Release Candidate
Config:
- blendConfigs: watchBlender, shimBlender &
build: optimize
specs - watchBlender for
after
,before,
files`
Build:
calcRequireJsConfig
neededDeps, strictDeps, shim- fixed:
hasErrors
should not be a cached prop
Bundle:
- loading dependencies.shim from bower paths
- fillDepsPaths() after all RCs
ResourceConverter.convert(fileResource, callback) accepts a promise returned, uses When.race for promise|callback
urequire exports 'dependenciesBindingsBlender', 'templateBlender', 'shimBlender', 'watchBlender'
urequire.addBBCreated & findBBCreated
afterBuild
throw errors handled gracefully
v0.7.0-beta6
BundleBuilder
- handling exceptions with promises
- runAfterBuildTasks always
- callback call version also deals (When.race) with possible returned promise.
- watch improved
Build:
- `Build::calcRequireJsConfig()
- calculates relative paths of local deps to dstPath, blends with another config, merges shims
- uses
bundle.dependencies.paths.override
always have precedence, then blended, then locals
- default automatic template.banner (true/function/hash)
- added
dstMainFilename
,dstMainFilepath
,dstMainRealpath
,dstRealpath
- added hasChanged, hasErrors, hasChangedErrors, changedErrorFiles, errors for last build
- refactored to
combine
and other responsibilities previously on bundle. - report:
- prints files in error in bundle / build & total errors
- Less verbose on errors & report only 1st time
Bundle:
- errorFiles
bundle.files
in error, - Resaving _combinedTemp always when missing and build.count > 1
- automatic loading package.json / bower.json
- improved Bundle::xxx_depVars handling with locals, node, bundle deps etc
Bundle.inferMain()
becomesBundle.ensureMain(force=true)
- calls
build.finishBuild()
even if no files changed
FileResource / Module:
- unique rootExports only
- knows if original AST has really changed.
dstFilenamesSaved
when saved,clean()
deletes em all,bundle.dstFilenames
has them all
templates:
- @globalSelector in both module & almond
- Almond template: __nodeRequire __throwMissing & __throwExcluded
exportRootCheck
works for nonscript
for real
urequire: addBBExecuted(bb) & findBBExecutedBefore(bb) & findBBExecutedLast(bb)
Dependency
- isLocal (_isInLocals) looks at all paths (bower, package etc)
- isNode looks at
dependencies.paths.node
(not yet implemented;-( - correct translation of './' to './index' if it exists
config:
- dependencies: paths:
- added
dependencies: paths: {ovverride, node, bower}
, bower --list paths invoked and paths results cached - fill deps paths at start only on first build
- added
- deprecate 'bundle.dependencies.exports.bundle' in favor of 'bundle.dependencies.imports'
- deprecate 'bundle.dependencies.exports.root' in favor of 'bundle.dependencies.rootExports'
- deprecate
buiild.done
in favor ofbuiild.afterBuild
- deprecate
build.exportsRoot
in favor of 'rootExports.runtimes' - deprecate
build.noRootExports
in favor of 'rootExports.ignore' - added 'rootExports.noConflict'
- dependenciesBindingsBlender uses
arrayizeUniqueReversingUnshifter
instead ofarrayizeUniquePusher
- blendConfigs: unique cfgs added once only
- added
build.target
, defaults to @target in grunt build.watch
is options, properly blended- project dependencies 'fsp', replaced
./paths/upath
withupath
- upath ravamped & spec-ed:
defaultExt
hasignoredExt
to cater for.min
/.dev
extensions- normalizeSafe deals correctly with './'
- trimExt accepts null ext
- changeExt accepts
ext
or.ext
v0.7.0-beta4: Almost done(), asynchronous postBuildTasks & bundleBuilder instance resolved
BundleBuilder.buildBundle :
- promise always returns bb instance
- runs done() async tasks serially, passing (err, bb) or (err, bb, callback) or compatibility (true/false) with older grunt-urequire / urequire-cli
- specs for done() tasks, then (bb)->, failing catch(err)
v0.7.0-beta3
Reverting to gaze 0.5.x due to windows build problems
v0.7.0-beta2
build.watch
:- can be the _.debounce wait, defaults to 1000 (from
urequire-cli
) - better logging output
- can be the _.debounce wait, defaults to 1000 (from
- bundleBuilder.buildBundle().then ()-> resolves it self
- specs:
- ResourceConverter unskipping
- blendConfigs with resources as RC-names []
- clean / update deps
ResourseConverters: Promising, Asynchronous, Pluggable & Reusable
ResourceConverters:
- fix #30 - Both Synchronous & Asynchronous (nodejs callbacks & A+ promises) ResourceConverters
- fix #58 - RC's have options :
a) When creating using the alternative array []
format its the *last item, or it can take the place of convFilename
if that is misisng.
b) When searching, a ['rcname', {some: 'option'}]
style lookup can be used that updates options
. It allows a changed filez
shortcut like ['less', ['myStyle/**/*.less'], { $srcMain: 'style/myMainStyle.less'} ]
- fix #57 - loading RCs from
node_modules/urequire-rc-#{rcname}
if not already on registry. - RC properties passed along with
options: {$: {srcMain:'...', convertFilename: '...'}}
oroptions: { $srcMain: '...', $convertFilename: '...' }
- If the same RC appears in
bundle.resources
more than once, only the last declared one remains. Effectively you change its position. If you really want them twice, clone 'em :-) - All
FileResource
<--TextResource
<--Module
instances now have asrcMainFilepath
&srcMainRealpath
property. - Bug fixed when instantiated and registered a new ResourceConverter
config:
build.deleteErrored
(cleans dst file while src is in error)
Internal / refactoring:
Bundle:
- Many methods now return when/A+ promises
- Minimized usage of
when.promise(resolve, reject)
-when.node.lift
is much better. getBundleFile
methodsrcMain
handling / throwing if not in @filenames- better duplicate src error handling (but still jerky on watch)
- clean dst when source is missing
- improved bundle.printError
Module.convert(@build)
urequire-spec:
- cloning & copying ../urequire_example to temp/urequire_example
Maintenance backport from v0.7.0
fix #59: [AMD / define in LiveScript / coco breaks (pre-define-ifi-statements)] - preDefineIFI statements are also those AFTER define, not only before it
fix #36 fix #49: exportsRoot
: selective root exporting at build, depending on runtime
Bundle: adding exports.bundle
(i.e combinedTemplate.exportsBundle_bundle_depsVars
_ to combined template (i.e the RequireJS build's deps
array).
NodeRequirer: fix bug with RequireJS returning undefined module instead of throwing
More nodejs compatibility
- appending
'/index'
on commonJsrequire('./some/dirname')
when'./some/dirname/index.js'
is present
Maintainance release
- updating outdated deps (except gaze@v0.5.x)
- travis tests only for node@v0.10
- ignoring "raw" in esprima.parse / AST
AMD Simplified CommonJS wrapper --> nodejs template fixes
- FIXED: AMD params with no/empty deps array was missintepreted fix #56
- FIXED: AMD deps with no params not loading on nodejs template (module.nodeDeps was lacking + template ommited)