Comments (6)
I will
from tmpl.
@GianlucaGuarini , I push to the master brach this time, next PRs will go to the dev branch.
This version will pass all text, except:
https://github.com/riot/riot/blob/2.3.0/test/specs/tmpl.js#L133
expect(render('{ loading: !nonExistingVar.length }')).to.equal('loading')
Please comment that line, or change 'loading' to the empty string.
This change in the behavior of shorthands was for consistency with the evaluation of other expressions, now property accessors for undefined variables generate error, so that the resulting expression is blank.
There's a new folder ./src
with commented code, I'm using ./rmcomms
for cleanup the resulting file ./lib/index.js
and conditionally include debugging code.
This is called by the Makefile, and it should be transparent to other parts of riot.
Note:
I'm disappointed with eslint 1.0, misaligned variables are poorly readable for me and sometimes is needed use extra parentheses to increase readability, so I returned to the previous version, but if there are problems I will use the new one.
from tmpl.
@aMarCruz well done! I am not sure we need 2 folders src
and lib
probably you can just use dist
for the output like @cognitom does for riot-route
https://github.com/riot/route/tree/master/dist
from tmpl.
Thanks.
for partial tools like tmpl I think 'lib' seems appropriate, anyway, /dist is a good name.
Please review this tree:
\ // <-- root, with copy of tmpl.js?
\src // <-- commented source files
\dist // <-- tmpl.js , riot-tmpl.js or index.js ? with minified versions.
\test
from tmpl.
I prefer the riot-route
folder structure:
\lib // <-- commented files
\dist
tmpl.riot.js <-- no umd
tmpl.min.js <-- minified
tmpl.js <-- umd wrappers
Remember also to change in package.json
the path to the UMD release https://github.com/riot/route/blob/master/package.json#L5
from tmpl.
this issue got solved
from tmpl.
Related Issues (13)
- Can't output expressions without evaluation HOT 2
- isRaw is returning false if the expression contains other text content before the template delimiters HOT 10
- Safe eval HOT 1
- Supporting ordered keys for objects HOT 5
- Each loops, __checked doesn't work HOT 2
- Render unescaped HTML HOT 25
- Making Handlebars work: Should riot-tmpl ignore {{expr}} but not {expr}? HOT 3
- Problem with backslash HOT 2
- Falsy value should not always be converted to empty string. HOT 1
- Yo can use brackets <% %> anymore HOT 1
- Unable to find tmpl.parse in the 2.3.0-beta.2 release HOT 12
- Changing brackets and expression cache HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tmpl.