Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: paularmstrong/swig
base: v0.9.0
...
head fork: paularmstrong/swig
compare: master
This comparison is big! We’re only showing the most recent 250 commits
Commits on Aug 16, 2013
@paularmstrong add special parser callback types 5b4a192
Commits on Aug 17, 2013
@paularmstrong move custom tags docs to new extending page 1bbb8df
@paularmstrong pave way for custom filters in extending page ec8f4a0
@paularmstrong Merge branch 'docs/custom-tags' of github.com:paularmstrong/swig into…
… docs/custom-tags

Conflicts:
	Makefile
	docs/docs/tags.html
4e599b1
@paularmstrong whitespace 4362e06
@paularmstrong add docs for custom filters 92bbd1c
@paularmstrong Filters work over arrays/objects if possible. Fixes gh-259 c05a5eb
@paularmstrong add sort filter eb31399
@paularmstrong make reverse filter an alias for sort(true) 814a5ad
@paularmstrong dont cp coverage, it's already built to tmp 7aa1645
@paularmstrong add filename to errors if possible. Fixes gh-280 fd1e05d
@paularmstrong throw error if reserved word is used as var. Fixes gh-276 65fa334
@paularmstrong prevent circular extends. Fixes gh-282 03925df
Commits on Aug 18, 2013
@paularmstrong document cache control. Fixes gh-265 8f15352
@paularmstrong document file resolution for in-browser. theoretically, it works this…
… way
ba23716
@paularmstrong allow asyncronous compileFile and renderFile operations. Fixes gh-283 7f6b37e
@paularmstrong allow method-name to be a shortcut for wrap-start var setting 61dc79b
@paularmstrong ensure that if fs.readFile* throws informative error in browser 8ddd511
@paularmstrong update docs for browser/cli 434435e
@paularmstrong version bump 1.0.0-pre2 7c0d84c
@paularmstrong docs version number d1b6983
Commits on Aug 19, 2013
@paularmstrong fix tests for browser-running 7ba5242
@paularmstrong udpate dev dependencies 9ad39d9
@paularmstrong preserve forward-slashes in text chunks. Fixes gh-285 3fea14d
Commits on Aug 20, 2013
@paularmstrong shallow copy options object if making changes to it. Fixes gh-287 9777453
@paularmstrong Allow tags at block-level if specified
Fixes gh-289
40f49a3
Commits on Aug 21, 2013
@paularmstrong ensure compileFile runs callback if cache found. Fixes gh-291 a185ea2
@paularmstrong add mailing list/stackoverflow to readme dac5a08
@paularmstrong version bump 1.0.0-pre3 8de22c0
@paularmstrong ignore tmp/ directory for lint 0e7f650
@paularmstrong fix readme license to match LICENSE 76669ec
Commits on Aug 22, 2013
@paularmstrong add swig.version and -v to cli 1a9bdc0
@paularmstrong Update NPM description, keywords a001ce4
@paularmstrong add contribution instructions for documentation 87b4f60
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig 30c418c
@paularmstrong fix copyright date 6e880f0
Commits on Aug 24, 2013
@paularmstrong Fix some npm install ugliness 463bebd
@paularmstrong ensure comments are preserved in minified source 1730a33
@paularmstrong Add 'only' argument option to include tag. Closes gh-240 129139f
@paularmstrong fix macro docs example dee1293
@paularmstrong Deprecated 'raw' filter. Use 'safe'. For clarity 044cf6b
@paularmstrong alphabetize filters d96dd12
Commits on Aug 25, 2013
@paularmstrong fix include paths on windows. Fixes gh-295 fc17877
@paularmstrong fix bin tests on windows 1b821b5
@paularmstrong one more fix for bin test on windows c83e196
@paularmstrong Add FUNCTIONEMPTY and handle for applying filters. Fixes gh-296 0f6681f
Commits on Aug 27, 2013
@paularmstrong fix bug in for k,v tag syntax 2550595
@paularmstrong Do not auto-escape macros, marked filters
Filters can be marked as `safe` (See `safe`/`raw` filter for example)

Fixes gh-297
Closes gh-294
13ef8a1
@paularmstrong More fixes for not escaping macro content, gh-297 671a6f6
@paularmstrong Allow import and macro tags to be outside of blocks. Fixes gh-299 79eddee
@paularmstrong make use of import/macros in docs, per 79eddee 806623f
Commits on Aug 28, 2013
@paularmstrong clarify importing macros from current template a305c71
@paularmstrong version bump 1.0.0-rc1 3f42e87
Commits on Aug 29, 2013
@paularmstrong Fix performance issue with compile if no default locals are defined 709a06c
@paularmstrong Fix multiple redefinition of block-level tags 2270510
Commits on Aug 30, 2013
@paularmstrong README update 675e297
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig 8bc4ae4
Commits on Aug 31, 2013
@paularmstrong docs: filters.json uses -X from jsdoc 184bce4
@paularmstrong docs: tags.json uses -X from jsdoc 733421f
@paularmstrong docs api.json uses -X from jsdoc 3c57987
@paularmstrong docs: extending.json uses -X from jsdoc 7da5fe6
@paularmstrong remove jsdoc custom script 76166c4
@paularmstrong standardize variable undefined checking. Fixes gh-301 9da5c9a
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig 45fc3fe
Commits on Sep 01, 2013
@paularmstrong Fix issue and include test from @TheRoSS on gh-301 2424040
Commits on Sep 02, 2013
@paularmstrong don't require running every testcase for bin tests, just a random one 3bb53cb
Commits on Sep 03, 2013
@paularmstrong set tag assigns to the local ctx. Fixes gh-303 8176346
Commits on Sep 04, 2013
@paularmstrong delete accidental file addition 97d3792
Commits on Sep 05, 2013
@paularmstrong Fix swig.setDefaultTZOffset. Fixes gh-311 643faba
@paularmstrong Allow nested macros to work when importing. Fixes gh-310 603da5c
@paularmstrong Don't auto-escape any function output d81e94a
Commits on Sep 06, 2013
@paularmstrong Merge pull request #309 from paularmstrong/refactor/functions-not-aut…
…oescaped

Don't auto-escape any function output
3fb57c5
@paularmstrong clarify docs for functions and autoescaping ecd20b8
@paularmstrong add note about caching for express example in docs 2d30807
@paularmstrong version bump 1.0.0-rc2 2ec6b38
Commits on Sep 09, 2013
@fluentart fluentart fix readme example fbd1b4d
@paularmstrong Merge pull request #315 from fluentart/patch-1
fix readme example
defa063
Commits on Sep 12, 2013
@paularmstrong fix parent tag in parent's block with no local block edge case
Easier than I expected.

closes gh-316
2cafb3f
Commits on Sep 14, 2013
@paularmstrong Don't partially match logic words. Fixes gh-322 94c5d58
@paularmstrong Allow variables as object values. Fixes gh-323 735e918
@paularmstrong update macros example. Closes gh-318 34d5a6d
@paularmstrong update custom tag example. Fixes gh-317 e7bfe5c
@paularmstrong remove import macro warnings from docs, no longer true c2a5d3a
@paularmstrong Allow bools in token parser by default. Fixes gh-321 bbca4a7
@paularmstrong version bump 1.0.0-rc3 32ac200
Commits on Sep 20, 2013
@paularmstrong Fix all other word lexer matches to ensure not matched partially in v…
…ariables. Fixes gh-330
9979f5e
Commits on Sep 21, 2013
@paularmstrong Allow parent and other tags to work correctly nested in other tags. F…
…ixes gh-331
aa128e9
@paularmstrong cleanup unused variables ed4bc96
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig 701f259
@paularmstrong update package to require node >=0.8.0 182dd9a
@paularmstrong remove pre-release warning from docs 9fed4dc
@paularmstrong docs: add info to get previous versions 82b74a5
Commits on Sep 22, 2013
@paularmstrong added link to sublime text syntax highlighter. Closes gh-320 c87571a
Commits on Sep 23, 2013
@paularmstrong version bump v1.0.0 87958f0
Commits on Sep 25, 2013
@paularmstrong Allow logic in default parsing. Fixes gh-326 bb61e78
Commits on Sep 27, 2013
@paularmstrong Properly clone objects when applying filters to them. Fixes gh-337 f11074c
Commits on Oct 02, 2013
@paularmstrong Ensure spaceless only attempts to replace on string tokens. Fixes gh-336
567f9af
@paularmstrong Merge branch 'next-1.1.0' dc4660c
@paularmstrong version bump 1.1.0 94cf5a6
Commits on Oct 09, 2013
@bohnman bohnman When a callback is passed into compileFile, catch all errors thrown b…
…y compile and pass the error to callback
22d887a
@bohnman bohnman adding test case and linking dc8e49d
@paularmstrong Merge pull request #340 from bohnman/handle-compile-errors-gracefully
Catch errors and send to callback if compileFile fails.
f461f6e
Commits on Oct 10, 2013
@paularmstrong Add nodei.co badge to readme 9395e31
Commits on Nov 02, 2013
@paularmstrong Use local-context first for var lookups
Ensures that browser-globals are not used before using the local context.
Ensured resetting values in for-loops.

Fixes gh-347
Possibly related to gh-344
32f3994
@paularmstrong Fix order of paragraph in docs d4fbb67
@paularmstrong Add filepath parameter to swig.run
Allows files to be cached, thus letting extends/includes/import work in browsers.

Fixes gh-349
b544615
Commits on Nov 16, 2013
@logie17 logie17 Updated the docs regarding "swig.addTag" - it appears this is really
"swig.setTag".
2fc8eee
Commits on Dec 02, 2013
@paularmstrong add test for local-context-first output 7496794
@paularmstrong Merge pull request #358 from logie17/master
Updated the docs regarding "swig.addTag"
55ee959
@paularmstrong Allow DOTKEY after functions/objects/filters. Fixes gh-355 b15dd55
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig c4bcdde
@paularmstrong Add test showing for-context carries into includes. Closes gh-356 1359609
@paularmstrong Fix link in docs. Closes gh-359 f5025a1
@paularmstrong Call correct instance methods. Fixes gh-351
Closes gh-354
bf10643
@paularmstrong Update package dependencies to be a little lenient on patch versions 0ab64c1
@paularmstrong fix intermittent test 9c7da5c
@paularmstrong version bump 1.2.0 236ca16
@paularmstrong update version in docs a8f4f86
Commits on Dec 03, 2013
@paularmstrong Fix scoping for Express. Fixes gh-363 2ecef8f
@paularmstrong version bump 1.2.1 0d72bef
@paularmstrong Fix ctx var output in imported macros. gh-363 beb37a2
@paularmstrong version bump v1.2.2 9532f53
Commits on Dec 28, 2013
@cyberwombat cyberwombat Update dateformatter.js
Corrected date calculation for day of week
546b1b6
@cyberwombat cyberwombat Added/modified day of week tests
This matches PHP:
echo date('N', strtotime('2011-09-06T16:05:02.000Z'))."\n";
echo date('N', strtotime('2011-09-04T16:05:02.000Z'))."\n";
2de7bd6
Commits on Dec 30, 2013
@MaratFM MaratFM Extract file system based functions into template loaders 2d4fc67
Commits on Dec 31, 2013
@MaratFM MaratFM added test with include 4bee340
@MaratFM MaratFM export loaders 734f7df
Commits on Jan 02, 2014
@paularmstrong Move loader files, rename, add path resolving to memory loader f3c88e0
@paularmstrong Don't use class-based loaders, update some documentation 392cffd
@paularmstrong fix getting parent from cache. closes gh-378 6f1ee56
Commits on Jan 07, 2014
@paularmstrong Add page for template loader docs, fix typo 3667bb9
Commits on Jan 08, 2014
@paularmstrong Promot groupBy filter from swig-extras. Closes gh-383 09f7e24
Commits on Jan 09, 2014
@paularmstrong add basic filesystem tests 4e3cd7a
@MaratFM MaratFM Extract file system based functions into template loaders de58ebe
@MaratFM MaratFM added test with include a79182f
@MaratFM MaratFM export loaders f492852
@paularmstrong Move loader files, rename, add path resolving to memory loader f26dd67
@paularmstrong Don't use class-based loaders, update some documentation d87e65f
@paularmstrong Add page for template loader docs, fix typo cee4e3f
@paularmstrong add basic filesystem tests bff6c57
Commits on Jan 10, 2014
@hegemonic hegemonic Allow set tag to use bracket notation for object properties dcc9de6
@paularmstrong Docs 2b6bce7
@paularmstrong Fix base path lookups, add to memory loader f311295
@paularmstrong Merge branch 'feature/template-loaders' of github.com:paularmstrong/s…
…wig into feature/template-loaders

Conflicts:
	docs/docs/loaders.html
	lib/loaders/filesystem.js
	lib/loaders/index.js
	lib/loaders/memory.js
	lib/swig.js
	tests/loaders.test.js
66184f7
@paularmstrong Allow set to use mixed bracket and dot-notation d29067a
@paularmstrong Merge pull request #375 from cyberwombat/master
Fix date formatting for 'N' (ISO-8601 numeric representation of the day of the week)
d70b853
@paularmstrong Merge branch 'master' into feature/template-loaders b79f6f4
@paularmstrong Remove official node v0.8.x support de0090d
Commits on Jan 12, 2014
@paularmstrong fix applying filters to functions w/ & w/o dotkeys. fixes gh-365 9aea1f4
@paularmstrong Merge branch 'master' into feature/template-loaders c01eb0e
Commits on Jan 13, 2014
@asabhaney asabhaney Added arguments for custom tags and filters to CLI 6cc983a
@asabhaney asabhaney Merge remote-tracking branch 'upstream/master' into cli-additions c9a9ca9
Commits on Jan 14, 2014
@asabhaney asabhaney Added bin tests for compliling & running w/ custom filters & tags d53866f
@asabhaney asabhaney Updated docs & bin usage 23cd09b
@asabhaney asabhaney added newline characters at eof of new files 7ca7cf5
Commits on Jan 17, 2014
@paularmstrong Merge branch 'cli-additions' of github.com:asabhaney/swig into asabha…
…ney-cli-additions
ebe153a
@paularmstrong cleanup/stylistic changes to bin code 9d98353
@paularmstrong move bin tests to directory fefd04f
Commits on Jan 19, 2014
@paularmstrong Fix filter idx applied to parenclose with args. Fixes gh-397 aad98f8
Commits on Jan 20, 2014
@paularmstrong Ensure swig.run filepath arg is optional.
Fixes gh-402
c353323
@paularmstrong Add tests for swig.run e70049a
@paularmstrong remove unnecessary parsing from autoescape tag 5ccda20
@paularmstrong increase some test coverage 28864a6
@paularmstrong version bum v1.3.0 2ca01a4
Commits on Jan 22, 2014
@tvavrys tvavrys Fixes "include" tag compilation when parentFile is null 8eb6fc2
Commits on Jan 24, 2014
Dan Harbin Make swig compile on IE8 d944ad2
Commits on Jan 26, 2014
@lukaszb lukaszb Null should yield empty string when resolving variable 91394b5
Commits on Jan 28, 2014
@paularmstrong Fix some loop vars for objects. Fixes gh-409 1eeeacd
@paularmstrong remove duplicate tests e30fd4e
@paularmstrong Merge pull request #410 from RasterBurn/master
Make swig compile on IE8
8cd0f2f
@paularmstrong Merge branch 'master' of github.com:tvavrys/swig into tvavrys-master 3c46585
@paularmstrong Add test for include with no parentFile 50358d7
@paularmstrong Fix looping over non-existent object 5cfc2ba
@paularmstrong ensure loaders docs are built properly f004dd9
@paularmstrong version bump v1.3.1 b7d45dc
@paularmstrong version bump 1.3.2 (npm is not force-updating) 6f1902e
Commits on Feb 02, 2014
@d42f d42f cli: presetting module.
Change default options (varControls, tagControls and etc).
bedcf08
Commits on Feb 03, 2014
@paularmstrong cleanup bin options param 66b794c
@paularmstrong add docs for --options bin param 4863896
Commits on Feb 08, 2014
@paularmstrong simplify bin tests, make pass on node 0.11 62936d5
Commits on Feb 10, 2014
@p-baleine p-baleine handle errors which occur at the time of rendering
Erros could be thrown at the time of rendering instead of compiling
when functions are called in templates. By this correction,
the exception which occurs in renderFile at the time of rendering
is passed to a callback.
c5ab672
@paularmstrong Move test to use memory loader / don't hit the filesystem a2100ac
Commits on Feb 11, 2014
@gustavohenke gustavohenke fs loader should take cwd as default base path 80343e4
@paularmstrong Merge pull request #419 from gustavohenke/patch-1
Fixed fs loader to default to cwd if no basepath or relative
6cff764
Commits on Feb 20, 2014
@greelgorke greelgorke make if and elseif throw a better error message when a tag body is om…
…itted
2fe22da
@greelgorke greelgorke fixed typo 8ab5bfb
Commits on Feb 25, 2014
@paularmstrong require es5 (no trailing commas)
closes gh-428
87bc42b
Commits on Mar 05, 2014
@ecaron ecaron Introducing the escape character, as discussed in #427 33be4ef
@ecaron ecaron Fixing a bad comment 0e71148
Commits on Mar 06, 2014
@paularmstrong Make loop cache unique. Fixes gh-433 e758c0c
@paularmstrong Merge pull request #408 from lukaszb/null-should-yield-empty-string
Null must yield empty string when printing variables === `null`. Fixes gh-408, Fixes gh-236
4b61275
Commits on Mar 07, 2014
@paularmstrong Merge branch 'master' of github.com:ecaron/swig into ecaron-master 43640f7
@paularmstrong Add more real-world test for escaping date format 0dbe44f
@paularmstrong Remove quotes from filter names in docs 3dda258
@paularmstrong Merge branch 'master' of github.com:paularmstrong/swig 324423a
@paularmstrong Merge branch 'master' of github.com:greelgorke/swig into greelgorke-m…
…aster
57c2dae
@paularmstrong Solidify tests for requiring conditional in if statements 3855260
Commits on Apr 25, 2014
senorcris adding support for referencing object properties that start with '$' c0a2c2f
Commits on May 07, 2014
@paularmstrong Merge pull request #455 from senorcris/bug/dotkey
Allow variable tokens to start with `$`
9b75436
Commits on May 27, 2014
@finnsoft finnsoft Fixed null object property 0eaf9b8
Commits on Jun 27, 2014
@paularmstrong Merge pull request #471 from finnsoft/master
Fixed: don't throw errors on accessing property of null object
8475519
Commits on Jul 01, 2014
@zmetcalf zmetcalf Removed excess code in lib.swig.setDefaults 27102c8
Commits on Jul 03, 2014
@paularmstrong version bump 1.4.0 821ee89
@paularmstrong Fix filter chaining within tags. Fixes gh-441 a93d67b
@paularmstrong Fix macro argument names colliding with context variable names. Fixes g… 37f90df
@paularmstrong Merge pull request #487 from zmetcalf/setDefaults_cleanup
Removed excess code in lib.swig.setDefaults Issue #485
948a47f
@paularmstrong Add test to show null values do not print [object object]
Closes gh-474
3bdf71c
@paularmstrong version bump 1.4.1 3948566
@paularmstrong fix docs 02560d5
Commits on Jul 29, 2014
@logie17 logie17 Fixing issue #499
* Prior to version 1.4.1 the output of a macro could be assigned to a variable
  with "set" - this restores that bahavior.
1af0706
@logie17 logie17 Prepending the test with the issue number 7ce80b4
@paularmstrong Merge pull request #502 from logie17/master
Allow macro output to be assigned via `set` tag. Fixes gh-499
0d465ad
@mweibel mweibel Report parse errors with template filenames
Closes #492
3b3d107
@paularmstrong Fix for-loops to run on strings
Closes #478
Closes #479
6eb1d15
@paularmstrong Ensure compilation does not leak global variables. Fixes gh-496 74d2f81
@paularmstrong Update readme badges 6dc7d4f
@paularmstrong fix space in readme badges e0d663b
@paularmstrong remove npm big badge df861c1
@paularmstrong Allow disabling cache on compile/render functions directly. Fixes gh-423
9aaba15
Commits on Jul 30, 2014
@paularmstrong Ensure import tag uses current Swig instance's loader
I'm not sure of a good way to test this yet.

@gustavohenke: does this satisfy gh-421 ?
51a7a2b
@paularmstrong Fix order of block-level tag compilation. Fixes gh-495 8b11511
@paularmstrong Merge pull request #503 from paularmstrong/refactor/421-import-loader
Ensure import tag uses current Swig instance's loader. Fixes gh-421
2e0e135
@paularmstrong ensure travis uses node v0.10, not v0.1 77090d2
Commits on Aug 04, 2014
@paularmstrong bump version 1.4.2 08109dc
Commits on Aug 07, 2014
@paularmstrong Force jsdoc to 3.2.0. Fixes #506 2c5e564
Commits on Aug 13, 2014
@paularmstrong Fix not being able to set method-name in swig cli 2089af6
@paularmstrong update blanket config 9a69b0c
@paularmstrong add test for bad set tag syntax 5f72078
Commits on Sep 18, 2014
@wilsaj wilsaj add a length filter that works for objects as well as arrays and strings e155cd3
@wilsaj wilsaj in length filter: use if (input.hasOwnProperty('length') (to be more …
…strict)
84dabee
Commits on Sep 19, 2014
@wilsaj wilsaj length filter should return empty string if not an object or array 5dfce50
@paularmstrong Merge pull request #520 from wilsaj/add-length-filter
add a length filter that works for objects as well as arrays and strings
84b4eaf
Commits on Sep 29, 2014
@wilsaj wilsaj test if applying a filter has permanently changed the original value 8b9a044
@wilsaj wilsaj fix groupBy filter so it doesn't permanently mutate the list items e9a5ad6
@wilsaj wilsaj fix sort filter so it doesn't permanently mutate the list 24645c8
Commits on Oct 10, 2014
@vingiarrusso vingiarrusso Fix documentation for import 6ba2eae
Commits on Oct 13, 2014
@paularmstrong Merge pull request #524 from wilsaj/fix-filter-mutation
fix value mutation in sort and groupBy filters
c9c0cd3
Commits on Oct 19, 2014
@paularmstrong Merge pull request #527 from vingiarrusso/master
Fixes import example typo
73cb7c1
Commits on Oct 25, 2014
@janka102 janka102 Ensure a non-word character is after the name
This fixes if the macro name is at the beggingin of the import name
79b6821
@janka102 janka102 Fixes if a macro name is exactly the import name 208ced7
@janka102 janka102 Added tests to check for cases like #521 bc5d9c7
@janka102 janka102 Updated macroExpectation because I added macros 9802c96
@janka102 janka102 Fixed linting 5b72bf1
Commits on Oct 26, 2014
@janka102 janka102 Do the whitespace replace on the whole output, not each token a65ecfe
@janka102 janka102 Changed some tests based on what I think it should actually be
I don't think a macro in a spaceless tag should be affected, but when a
macro is used the output of it should be affected
f89b78e
Commits on Oct 31, 2014
@paularmstrong Merge pull request #534 from janka102/fix-#526
Fixed spaceless tag stripping too much (#526)
90ac5cc
@paularmstrong Merge pull request #533 from janka102/fix-#521
Fixed colliding macro names and import names (#521)
2d2749e
Commits on Jan 13, 2015
@jpetitcolas jpetitcolas Fix typo 95b7648
@paularmstrong Merge pull request #565 from jpetitcolas/master
Fix typo
a86b63d
Commits on Jun 25, 2015
@paularmstrong Update with link to maintaining announcement 20b20e7