Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Socket
Sign inDemoInstall

vash

Package Overview
Dependencies
Maintainers
1
Versions
81
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vash - npm Package Compare versions

Comparing version 0.9.1 to 0.9.2

2

build/vash-runtime.js

@@ -27,3 +27,3 @@ !function(e){if("object"==typeof exports)module.exports=e();else if("function"==typeof define&&define.amd)define(e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.vash=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){

"description": "Razor syntax for JS templating",
"version": "0.9.1",
"version": "0.9.2",
"author": "Andrew Petersen <senofpeter@gmail.com>",

@@ -30,0 +30,0 @@ "homepage": "https://github.com/kirbysayshi/vash",

@@ -25,3 +25,3 @@ // The order of these is important, as it is the order in which

// However, this is "Good Enough"© :).
'EMAIL', (/^([a-zA-Z0-9.%]+@[a-zA-Z0-9.\-]+\.(?:ca|co\.uk|com|edu|net|org))\b/)
'EMAIL', (/^([a-zA-Z0-9.%]+@[a-zA-Z0-9.\-]+\.(?:[a-z]{2}|co\.uk|com|edu|net|org))\b/)

@@ -28,0 +28,0 @@ , 'AT_STAR_OPEN', (/^(@\*)/)

{
"name": "vash",
"description": "Razor syntax for JS templating",
"version": "0.9.1",
"version": "0.9.2",
"author": "Andrew Petersen <senofpeter@gmail.com>",

@@ -6,0 +6,0 @@ "homepage": "https://github.com/kirbysayshi/vash",

@@ -141,3 +141,3 @@ <!-- This document was generated from README.vash -->

<script type="text/javascript" src="vash.min.js"></script>
<script type="text/javascript" src="build/vash.js"></script>

@@ -147,2 +147,4 @@ var tpl = vash.compile( '<p>I am a @model.t!</p>' );

But you should probably be precompiling your templates. See [Precompiling Templates][] for more info. Then you can just include the Vash runtime instead of the entire compiler.
<a name="browser---browserify-et-al"></a>Browser - Browserify et al

@@ -289,7 +291,7 @@ ----------------------------------

// model = { hasIceCream: true }
<p class="@( model.hasIceCream ? 'ice-cream' : '')">Ice Cream<p>
<p class="@( model.hasIceCream ? 'ice-cream' : '')">Ice Cream</p>
output:
<p class="ice-cream">Ice Cream<p>
<p class="ice-cream">Ice Cream</p>

@@ -1123,9 +1125,9 @@ You could even create an anonymous function.

-t, --target-namespace <namespace> Assign template to a <namespace>. Recommended is `vash.helpers.tplcache` for view engine compatibility
-p, --property-name [name] Assign template to property named <name>. Defaults to filename, and requires --target-namespace.
-p, --property-name [name] Assign template to property named [name]. Defaults to filename, and requires --target-namespace.
-f, --file <file> Compile the template in <file>
-j, --json <json> Pass options to the Vash compiler. See docs for valid options.
-o, --out <path> Write template into <path> directory
-o, --out <path> Write template into <path>' directory
-u, --uglify Uglify the template, safely
-a, --no-autolink Wrap each template in `vash.link`.
-r, --render [json] Render the template using <json> as the model. If <json> is not valid json, assume a filename and load those contents as json.
-r, --render [json] Render the template using [json] as the model. If [json] is not valid json, assume a filename and load those contents as json.
-s, --separator [separator] Templates are auto-named by concatenating the file path with [separator]

@@ -1132,0 +1134,0 @@ --helper Assume the input is a to-be-compiled helper

@@ -900,2 +900,10 @@ var vows = require('vows')

}
,'can have any two-letter tld-ish': {
topic: 'who@what.de'
,'and still register': function(topic) {
var tpl = vash.compile(topic);
assert.equal(tpl(), topic);
}
}
}

@@ -902,0 +910,0 @@ ,'explicit expression': {

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc