Socket
Socket
Sign inDemoInstall

@emmetio/snippets-registry

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@emmetio/snippets-registry - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

18

dist/snippets-registry.cjs.js

@@ -120,4 +120,18 @@ 'use strict';

var index = function() {
return new SnippetsRegistry();
/**
* Creates snippets registry, filled with given `data`
* @param {Object|Array} data Registry snippets. If array is given, adds items
* from array in order of precedence, registers global snippets otherwise
* @return {SnippetsRegistry}
*/
var index = function(data) {
const registry = new SnippetsRegistry();
if (Array.isArray(data)) {
data.forEach((snippets, level) => registry.add(level, snippets));
} else if (typeof data === 'object') {
registry.add(data);
}
return registry;
};

@@ -124,0 +138,0 @@

@@ -116,4 +116,18 @@ class Snippet {

var index = function() {
return new SnippetsRegistry();
/**
* Creates snippets registry, filled with given `data`
* @param {Object|Array} data Registry snippets. If array is given, adds items
* from array in order of precedence, registers global snippets otherwise
* @return {SnippetsRegistry}
*/
var index = function(data) {
const registry = new SnippetsRegistry();
if (Array.isArray(data)) {
data.forEach((snippets, level) => registry.add(level, snippets));
} else if (typeof data === 'object') {
registry.add(data);
}
return registry;
};

@@ -120,0 +134,0 @@

12

package.json
{
"name": "@emmetio/snippets-registry",
"version": "0.1.0",
"version": "0.1.1",
"description": "JavaScript module for storing and retrieving Emmet snippets",

@@ -10,6 +10,5 @@ "main": "dist/snippets-registry.cjs.js",

"build": "npm run build:cjs && npm run build:es",
"build:cjs": "rollup -o dist/snippets-registry.cjs.js -f cjs ./index.js",
"build:es": "rollup -o dist/snippets-registry.es.js -f es ./index.js",
"prepublish": "npm run build",
"watch": "rollup -w -o dist/snippets-registry.cjs.js -f cjs ./index.js"
"build:cjs": "rollup -c -o dist/snippets-registry.cjs.js -f cjs ./index.js",
"build:es": "rollup -c -o dist/snippets-registry.es.js -f es ./index.js",
"prepublish": "npm run test && npm run build"
},

@@ -31,5 +30,4 @@ "repository": {

"mocha": "^3.1.2",
"rollup": "^0.36.3",
"rollup-watch": "^2.5.0"
"rollup": "^0.41.1"
}
}
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