summaryrefslogtreecommitdiffstats
path: root/spec/qunit_spec.js
Commit message (Collapse)AuthorAgeFilesLines
...
| | * Merge branch 'master' of http://github.com/wycats/handlebars.jsJason Davies2011-02-281-0/+75
| | |\
| | * | Merge branch 'master' of http://github.com/wycats/handlebars.jsJason Davies2011-02-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Conflicts: lib/handlebars.js test/index.html
* | | | Add ", ', and / to the list of chars that need HTML escaping.Ryan Grove2011-04-251-9/+9
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, only < and > were escaped. This meant that any Handlebars template that used user input in an HTML attribute value was wide open to a trivial XSS exploit. Note that unquoted attribute values are still open to attack, but this set of characters at least brings Handlebars in line with other Mustache implementations and other template languages. See the OWASP XSS prevention cheat sheet (rule #1) for the rationale behind escaping these characters: https://www.owasp.org/index.php/XSS_(Cross_Site_Scripting)_Prevention_Cheat_Sheet
* | | Add support for block hashes and clean up mustache/program codetomhuda2011-03-041-6/+15
| | |
* | | Add Hash arguments to simple mustaches (TODO: add Hash args to block helpers)tomhuda2011-03-041-23/+34
| |/ |/|
* | Helpers take precedence over context properties with the same name. This is ↵tomhuda2011-02-251-0/+44
| | | | | | | | useful in scenarios where your context object is inherited from another system (such as a framework or JSON API) that may contain properties that conflict with helpers you explicitly define.
* | Make the function passed to a block helper have an identical signature to ↵tomhuda2011-02-141-0/+31
|/ | | | top-level template methods
* data is passed to block helperstomhuda2011-02-111-0/+17
|
* * Added a few public API methods to JavaScriptCompiler.prototype, so it can ↵tomhuda2011-02-111-2/+67
| | | | | | | | | | | | be subclassed. * made it possible to define an alternate name lookup scheme (so that {{foo}} does not have to be context.foo, but can instead be something like context.get('foo')) * made it possible to substitute an alternate buffer instead of the default empty String and override how the compiled template appends to the buffer * Added the concept of template-local data. In order to enable template-local data, pass true as the second parameter to the template compiler. Then, pass in the data as the fourth parameter (context, helpers, partials, data). These signatures may change before the 1.0 release.
* Backed out function helpers.Alan Johnson2011-01-251-34/+4
|
* Added test for undefined blocks - didn't matter though.Alan Johnson2011-01-251-0/+4
|
* improved "with" and "each" helpers to support function as argumentRaimonds Simanovskis2011-01-231-1/+27
|
* MergedAlan Johnson2011-01-221-0/+24
|\
| * improved "if" helper to support function as argumentRaimonds Simanovskis2010-12-281-0/+24
| |
* | Updated semanticswycats2010-12-291-4/+4
|/
* Add a #with helperwycats2010-12-211-1/+9
|
* Add optimized compiled version of handlebars, which should be significantly ↵wycats2010-12-181-26/+40
| | | | | | | | | | | faster. Use Handlebars.VM.compile instead of Handlebars.compile to use the optimized version. Major TODOS: * clean up a bunch of code duplication in the compiler * reorganize the compiler * add support for debug symbols which would make it possible to provide information about what part of the source caused a runtime error.
* Everything is working now on the new VM except for partials and inverse sectionswycats2010-12-151-3/+3
|
* Allow helperMissing to apply to simple mustaches (paves the way to support ↵wycats2010-12-111-0/+14
| | | | things like link_to in a Rails context)
* Make helperMissing a built-in featurewycats2010-12-111-23/+7
|
* Make it possible to register helpers and partials and then skip passing in ↵wycats2010-12-111-5/+5
| | | | the helpers or partials later
* Finish compatibility with the old handlebars:wycats2010-12-031-6/+11
| | | | | | * foo"bar" is an invalid param * {{foo}}bar{{/baz}} is invalid * fix a number of issues with inverse sections * add partials
* A few more lingering bugs:wycats2010-12-031-0/+4
| | | | | | | * add helperMissing.not to the specs * add Handlebars.Utils.isEmpty * add runtime handling for inverse sections * fix __get__ to pass an IdNode to evaluate * handle case in wrapProgram where context is undefined
* Fix a number of outstanding issues:wycats2010-12-021-1/+10
| | | | | | | | | | | | * {{}} escape their contents, {{{}}} and {{& }} do not * Add support in the parser, tokenizer and AST for partials with context (support is still not there in the runtime) * Fix some inconsistencies with the old behavior involving the correct printing of null and undefined * Add Handlebars.Exception * Fixed an issue involving ./foo and this/foo * Fleshed out helperMissing in the specs (this will be moved out into handlebars proper once registerHelper and registerPartial are added)
* Got Qunit tests running through RSpec and fixed a bunch of bugs... 33 fails ↵wycats2010-11-281-0/+459
from the original suite to go