Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
| * | Fix duplicate return statement on simple templates | kpdecker | 2014-12-27 | 1 | -1/+1 | |
| | | ||||||
* | | Fix case-insensitive file system compile issue | kpdecker | 2014-12-26 | 1 | -1/+1 | |
| | | ||||||
* | | Add parent tracking and mutation to AST visitors | kpdecker | 2014-12-26 | 1 | -35/+78 | |
|/ | | | Fixes #916 | |||||
* | Bump code coverage | kpdecker | 2014-12-26 | 4 | -2/+7 | |
| | ||||||
* | Implement block parameters | kpdecker | 2014-12-26 | 5 | -51/+135 | |
| | | | Fixes #907 | |||||
* | Expose AST helpers in public API | kpdecker | 2014-12-21 | 2 | -21/+26 | |
| | ||||||
* | Update fix for #926 for 3.0 codeline | kpdecker | 2014-12-17 | 1 | -1/+1 | |
| | ||||||
* | Track depths on deduped children | kpdecker | 2014-12-16 | 1 | -0/+2 | |
| | | | | | Fixes a very specific error case where deduped children won’t receive the depths object due to it being omitted by the caller when optimizing. Fixes #926 | |||||
* | Avoid unnecessary this. reference | kpdecker | 2014-12-16 | 1 | -3/+3 | |
| | ||||||
* | Fix remaining depth arg | kpdecker | 2014-12-16 | 1 | -1/+0 | |
| | ||||||
* | Remove unused vars and add jshint checking | kpdecker | 2014-12-16 | 7 | -10/+3 | |
| | ||||||
* | Remove Compiler.depths parameter | kpdecker | 2014-12-16 | 2 | -19/+7 | |
| | | | | This is no longer necessary with the depths array tracking and adds compiler overhead. | |||||
* | Add instructions for 'spec/mustache' to CONTRIBUTING.md, fix a few typos ↵ | Or Neeman | 2014-12-07 | 3 | -3/+3 | |
| | | | | elsewere | |||||
* | Add basic docs for JavaScriptCompiler override API | kpdecker | 2014-11-29 | 1 | -9/+9 | |
| | ||||||
* | Drop unused JavaScriptCompiler.namespace param | kpdecker | 2014-11-29 | 1 | -2/+0 | |
| | ||||||
* | Move compileProgram out of visitor methods | kpdecker | 2014-11-29 | 1 | -18/+18 | |
| | ||||||
* | Track source node via accept call rather vs opcode | kpdecker | 2014-11-29 | 1 | -41/+46 | |
| | ||||||
* | s/Subexpression/SubExpression/ | kpdecker | 2014-11-29 | 1 | -1/+1 | |
| | ||||||
* | Rework strip flags to make clearer at in AST level | kpdecker | 2014-11-28 | 4 | -188/+239 | |
| | | | Rather than keeping state in the AST, which requires some gymnastics, we create a separate visitor flow which does the top down iteration necessary to calculate all of the state needed for proper whitespace control evaluation. | |||||
* | Move Jison parsing out of AST into helpers | kpdecker | 2014-11-28 | 2 | -38/+46 | |
| | ||||||
* | Add original to BooleanLiteral | kpdecker | 2014-11-28 | 1 | -1/+2 | |
| | ||||||
* | Rename AST objects to match type names | kpdecker | 2014-11-28 | 2 | -16/+16 | |
| | ||||||
* | Treat partial exec in a manner closer to helpers | kpdecker | 2014-11-27 | 4 | -48/+50 | |
| | | | This helps unify the code handling and will also be needed to support string/id tracking on partials. | |||||
* | Update subexpression and hash AST constructs | kpdecker | 2014-11-27 | 6 | -105/+104 | |
| | ||||||
* | Simplify Path and Sexpr calculated flags | kpdecker | 2014-11-27 | 2 | -25/+38 | |
| | ||||||
* | Replace DataNode and IdNode with PathNode | kpdecker | 2014-11-26 | 5 | -55/+42 | |
| | | | This is a breaking change for string mode users as there is no longer a distinct type for data parameters. Instead data consumers should look for the @ prefix value. | |||||
* | Update literal ast nodes for new spec | kpdecker | 2014-11-26 | 5 | -26/+23 | |
| | ||||||
* | Update statement node ASTs | kpdecker | 2014-11-26 | 5 | -147/+133 | |
| | ||||||
* | Update MustacheNode for new AST structure | kpdecker | 2014-11-26 | 4 | -25/+14 | |
| | ||||||
* | Update ProgramNode to better match SpiderMonkey | kpdecker | 2014-11-26 | 6 | -61/+62 | |
| | ||||||
* | Update AST location info to match SpiderMonkey | kpdecker | 2014-11-26 | 7 | -50/+52 | |
| | | | Part of #889 | |||||
* | Make each helper data uniform | kpdecker | 2014-11-26 | 1 | -19/+26 | |
| | | | | | Provide @key and @last value for all forms of iteration. Fixes #910 | |||||
* | Provide Handlebars.noConflict implementation | kpdecker | 2014-11-26 | 2 | -0/+18 | |
| | | | | | Allows for users who are loading via a global pattern to avoid conflicting with other instances of the library. Fixes #887 | |||||
* | Lookup partials when undefined | kpdecker | 2014-11-25 | 1 | -0/+3 | |
| | ||||||
* | Optimize variable declaration | kpdecker | 2014-11-25 | 1 | -2/+1 | |
| | ||||||
* | Add parser support for block params | Martin Muñoz | 2014-11-11 | 3 | -2/+14 | |
| | ||||||
* | Propagate options for client compiled partials | kpdecker | 2014-11-08 | 2 | -1/+3 | |
| | | | Fixes #901 | |||||
* | Merge branch 'remove-block-mustache' of github.com:mmun/handlebars.js into ↵ | kpdecker | 2014-11-08 | 4 | -26/+31 | |
|\ | | | | | | | | | | | | | | | mmun-remove-block-mustache Conflicts: lib/handlebars/compiler/helpers.js spec/parser.js | |||||
| * | Remove RawBlockNode in favor of prepareRawBlock helper | Martin Muñoz | 2014-11-05 | 2 | -9/+3 | |
| | | ||||||
| * | Simplify BlockNode by removing intermediate MustacheNode | Martin Muñoz | 2014-11-02 | 4 | -20/+31 | |
| | | ||||||
* | | Only provide aliases for multiple use calls | kpdecker | 2014-11-08 | 1 | -26/+39 | |
| | | | | | | Fixes #903 | |||||
* | | Provide default mapping for boilerplate code | kpdecker | 2014-11-08 | 1 | -1/+5 | |
| | | ||||||
* | | Add source map output support to the CLI | kpdecker | 2014-11-08 | 1 | -20/+57 | |
| | | ||||||
* | | Generate source maps | kpdecker | 2014-11-08 | 2 | -100/+275 | |
| | | | | | | | | | | | | Allow the precompiler to generate source maps when the srcFile parameter is passed. This refactors large chunks of the code generation pipeline, allowing metadata to be associated with code chunks as well as breaking out much of the code generation logic into a separate helper. | |||||
* | | Include location information in all opcodes | kpdecker | 2014-11-08 | 2 | -45/+50 | |
| | | ||||||
* | | Merge pull request #892 from wycats/else-if | Kevin Decker | 2014-11-08 | 1 | -7/+26 | |
|\ \ | | | | | | | Implement parser for else chaining of helpers | |||||
| * | | Implement parser for else chaining of helpers | kpdecker | 2014-10-27 | 1 | -7/+26 | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allows users to chain multiple helpers together using their inverse callbacks. I.e. ``` {{#if foo}} {{else if bar}} {{else}} {{/if}} ``` The control flow here effectively causes the helpers to be nested. The above is actually syntactic sugar for this: ``` {{#if foo}} {{else}} {{#if bar}} {{else}} {{/if}} {{/if}} ``` Any helper may be used in this manner, the only requirement is they support normal calls and inverse calls. Introduces a breaking change in that `{{else foo}}` may no longer be used as a root level operator. Instead `{{^foo}}` must be used. Fixes #72. | |||||
* | | | Use toHTML vs. instanceof checks for SafeString | kpdecker | 2014-11-08 | 2 | -3/+3 | |
| | | | | | | | | | | | | | | | | | | Allows for us to play nicely in environments such as Node that could have multiple versions of the library loaded. Also allows for implementors to provide their own behavior, provided they know what they are doing. Fixes #886 | |||||
* | | | Merge pull request #870 from max-b/master | Kevin Decker | 2014-11-08 | 1 | -0/+3 | |
|\ \ \ | | | | | | | | | Registering undefined partial throws exception. | |||||
| * | | | Registering undefined partial throws exception. | Maxb | 2014-09-19 | 1 | -0/+3 | |
| |/ / | ||||||
* | | | Simplify program generation logic | kpdecker | 2014-11-08 | 1 | -10/+2 | |
| | | | ||||||
* | | | Bump test coverage | kpdecker | 2014-11-08 | 2 | -3/+4 | |
| | | | ||||||
* | | | Ignore unused code paths | kpdecker | 2014-11-08 | 1 | -0/+2 | |
| | | | | | | | | | | | | We don’t want to remove these as the generic code may need it in the future, but these code paths are not triggered through the existing language constructs. | |||||
* | | | Merge setupParams and setupOptions | kpdecker | 2014-11-06 | 1 | -9/+2 | |
| | | | ||||||
* | | | Simplify flushInline implementation | kpdecker | 2014-11-05 | 1 | -19/+10 | |
| | | | ||||||
* | | | Use terinary operator for inline appends | kpdecker | 2014-11-05 | 1 | -7/+12 | |
| | | | | | | | | | | | | Allows for append operations to avoid breaking inline chain. | |||||
* | | | Provide stubbed visitor implementation | kpdecker | 2014-11-05 | 1 | -2/+58 | |
| |/ |/| | | | Part of #889 | |||||
* | | Add preventIndent option for partials | kpdecker | 2014-11-02 | 1 | -1/+6 | |
| | | | | | | | | | | This disables the standalone partial indent behavior required by the Mustache spec and allows for users to utilize partials in the same manner as under 1.x. Fixes #858 | |||||
* | | Allow whitespace control on comments | kpdecker | 2014-11-02 | 2 | -4/+8 | |
| | | | | | | | | | | This changes the call signature for the CommentNode constructor, which is a potentially breaking change for AST users. Fixes #866 | |||||
* | | Capitalization change in comments for consistency | Alex Jeng | 2014-09-23 | 1 | -1/+1 | |
|/ | ||||||
* | v2.0.0v2.0.0 | kpdecker | 2014-09-01 | 1 | -1/+1 | |
| | ||||||
* | Cleanup var names slightly | kpdecker | 2014-08-27 | 1 | -6/+6 | |
| | ||||||
* | v2.0.0-beta.1v2.0.0-beta.1 | kpdecker | 2014-08-26 | 1 | -1/+1 | |
| | ||||||
* | Render false literal as “false” | kpdecker | 2014-08-25 | 2 | -2/+4 | |
| | | | Fixes #827 | |||||
* | Prune unused code | kpdecker | 2014-08-25 | 5 | -8/+4 | |
| | ||||||
* | Expose default compatibility wrapper for umd build | kpdecker | 2014-08-25 | 2 | -0/+4 | |
| | ||||||
* | Add template isTop flag | kpdecker | 2014-08-25 | 1 | -0/+1 | |
| | ||||||
* | Fix compiler version tag | kpdecker | 2014-08-25 | 1 | -1/+1 | |
| | ||||||
* | Rev runtime version | kpdecker | 2014-08-25 | 1 | -2/+3 | |
| | ||||||
* | Refactor content blocks to ignore lines | kpdecker | 2014-08-25 | 1 | -57/+31 | |
| | | | | | We can simplify our previous standalone determination logic by merging content blocks again. Fixes #854 | |||||
* | Expose escapeExpression on the root object | kpdecker | 2014-08-25 | 1 | -0/+1 | |
| | ||||||
* | Allow passing depths to _child | kpdecker | 2014-08-25 | 2 | -6/+6 | |
| | ||||||
* | Optimize compiler opcode call | kpdecker | 2014-08-24 | 1 | -1/+3 | |
| | ||||||
* | Additional test coverage cleanup | kpdecker | 2014-08-23 | 2 | -8/+5 | |
| | | | Also fixes the template._child implementation which broke with the depthed work. | |||||
* | Restore helperMissing for ambiguous statements | kpdecker | 2014-08-23 | 1 | -1/+2 | |
| | | | | Fixes #318 (regression) Partial fix for #783 | |||||
* | Cleanup from code coverage report | kpdecker | 2014-08-23 | 3 | -16/+12 | |
| | ||||||
* | Move strip processing into AST helper logic | kpdecker | 2014-08-23 | 3 | -53/+67 | |
| | | | | | We already have to track these behaviors for the standalone parsing and rather than having two whitespace pruning implementations this moves all of the behavior into one place. Fixes #852 | |||||
* | Replace string value rather than add omit flag | kpdecker | 2014-08-23 | 2 | -3/+4 | |
| | ||||||
* | Add original value tracking to ContentNode | kpdecker | 2014-08-23 | 1 | -1/+1 | |
| | ||||||
* | Merge branch 'refactor-parser' of github.com:mmun/handlebars.js into ↵ | kpdecker | 2014-08-23 | 3 | -174/+177 | |
|\ | | | | | | | | | | | | | | | | | mmun-refactor-parser Conflicts: lib/handlebars/compiler/ast.js spec/ast.js src/handlebars.yy | |||||
| * | Refactor blocks, programs and inverses | Martin Muñoz | 2014-07-29 | 3 | -46/+56 | |
| | | ||||||
* | | Optimize replaceStack for inline methods | kpdecker | 2014-08-23 | 1 | -40/+24 | |
| | | | | | | Only use case was with inline input so most of this code was unnecessary. | |||||
* | | Remove unnecessary stack variable from blockHelper | kpdecker | 2014-08-23 | 1 | -4/+4 | |
| | | ||||||
* | | Do not flush subexpressions | kpdecker | 2014-08-23 | 1 | -7/+0 | |
| | | | | | | | | | | | | They are no longer duplicated with the new helper calling pattern and this also introduced stack corruption issues due to improper value lookups. Fixes #767 Fixes #768 | |||||
* | | Fix undefined handling for pathed lookups | kpdecker | 2014-08-15 | 1 | -4/+3 | |
| | | | | | | | | Fixes #837 | |||||
* | | Strip dead code from javascript compiler | kpdecker | 2014-08-15 | 1 | -9/+2 | |
| | | ||||||
* | | Fix compat partial exec without data | kpdecker | 2014-08-15 | 1 | -0/+2 | |
| | | ||||||
* | | Make depthed lookup call non-literal | kpdecker | 2014-08-15 | 1 | -1/+1 | |
| | | | | | | Prevents duplicate calls from being made. | |||||
* | | Provide better error on unexpected template | kpdecker | 2014-08-15 | 1 | -0/+4 | |
| | | | | | | Fixes #806 | |||||
* | | Additional test coverage | kpdecker | 2014-08-15 | 1 | -1/+1 | |
| | | ||||||
* | | Remove nested function eval in blockHelperMissing | kpdecker | 2014-08-14 | 1 | -2/+0 | |
| | | | | | | This only worked when a function returned a function, which was then evaluated. This seems like unexpected behavior so this was dropped. | |||||
* | | Fix compiler program de-duping | kpdecker | 2014-08-14 | 1 | -9/+19 | |
| | | ||||||
* | | Drop unused Compiler.disassemble method | kpdecker | 2014-08-14 | 1 | -24/+0 | |
| | | ||||||
* | | Drop unused DECLARE opcode | kpdecker | 2014-08-14 | 2 | -9/+1 | |
| | | ||||||
* | | Drop unused registerHelper inverse parameter | kpdecker | 2014-08-14 | 1 | -3/+2 | |
| | | ||||||
* | | Increase test coverage a touch | kpdecker | 2014-08-14 | 5 | -6/+9 | |
| | | ||||||
* | | Implement partial recursive lookup | kpdecker | 2014-08-14 | 2 | -7/+10 | |
| | | ||||||
* | | Inherit compat flag for partials | kpdecker | 2014-08-14 | 2 | -3/+6 | |
| | | ||||||
* | | Implement recursive field lookup in compat mode | kpdecker | 2014-08-13 | 3 | -8/+32 | |
| | | | | | | | | | | | | Provides the mustache behavior of recursive lookup without the use of depthed paths. Note that this does incur a fairly dramatic performance penalty for depthed queries. | |||||
* | | Avoid depth construction overhead for non-depthed | kpdecker | 2014-08-13 | 1 | -1/+1 | |
| | |