Features:
- 👨🔬 100% tests coverage;
- 💡 Lightweight - No external dependencies, all feature helpers has only weak dependencies;
- ⚖️ Compare values with conditions -
{{#if compare one '===' two}} ... {{/if}}
; - 🐒 Get/set Session (weak dependency) -
{{Session 'key' set='value'}}
,{{#if Session 'key'}} ... {{/if}}
; - 🔨 Use underscore's functions (weak dependency) -
{{#if _ 'isString' 'one'}} ... {{/if}}
; - 👨💻 Debug/log passed objects as a string to template -
{{log this.someVal 'string' object="value"}}
.
meteor add ostrio:templatehelpers
Use comparison, conditional, and logical operations right in the Blaze templates. Get access to Session
object ans stored values. Execute underscore
package methods. And debug Blaze templating data using log
helper.
Get or set session value from views via Session helper
Template debugging - Log arguments into browser's console with output into template
Execute underscore methods in template
Compare template data. Create conditional if
and unless
blocks.
Compare complex template data.
Compare single value against many (any of.. match).
- Clone this package
- In Terminal (Console) go to directory where package is cloned
- Then run:
# Default
meteor test-packages ./
# With custom port
meteor test-packages ./ --port 8888
- Sponsor via GitHub
- Support via PayPal
- Use ostr.io — Monitoring, Analytics, WebSec, Web-CRON and Pre-rendering for a website