Comments (2)
Hello you can reuse a string libary to do most common operations:
https://www.npmjs.com/package/string
https://www.npmjs.com/package/voca
Here is a sample implementation using voca.js, I just merge the modifier object with the voca object to get all the voca functions for free to use in the grammar syntax of tracery.
https://github.com/mycaule/epures/tree/master/modifiers
from tracery.
Thanks for the tip, that's useful for using it as a JS library!
My main reason for opening this was to be able to use it in @v21's excellent Cheap Bots, Done Quick! where end users can only enter the Tracery grammar.
See v21#4
from tracery.
Related Issues (20)
- Tracery2 has breaking changes with setting variables HOT 1
- capitalizeAll doesn't support Unicode properly
- Variable expansion breaks on commas in variable text. HOT 3
- Substitutions behave strangely inside bindings
- please add a license? HOT 3
- Feature request(?): change probabilities HOT 3
- how to build? HOT 1
- Modifiers not working / NPM Package probem HOT 2
- "super advanced" Actions behave differently from static ones. HOT 3
- "a" modifier doesn't account for cases like "useful" HOT 4
- Links on your website died
- Capitalize the first alphabet character
- Java port HOT 1
- Actions overriding existing rules HOT 3
- firstS modifier adds space on single word entries
- .ing does not work
- Plural for specific cases? HOT 1
- Some idea on how to implement the parameters for modifiers
- Not sure where to put this, but Tracery's former 'home' to tutorials, CrysyalCodePalace.com is getting domain squatted
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 tracery.