Comparing version 1.1.0 to 1.2.0
@@ -13,2 +13,10 @@ # Changelog | ||
## 1.2.0 | ||
* Feature | ||
* Exposes the StylesheetMap class that's used internally to create | ||
stylesheet. | ||
Usage: `import Stylesheet, { StylesheetMap } from 'stilr'` | ||
* Bug | ||
* Fixed stylesheet instanceof check | ||
## 1.1.0 | ||
@@ -15,0 +23,0 @@ * __Internal__ |
@@ -23,2 +23,5 @@ 'use strict'; | ||
var StylesheetMap = _Map; | ||
exports.StylesheetMap = StylesheetMap; | ||
exports['default'] = { | ||
@@ -28,3 +31,3 @@ create: function create(styles) { | ||
if (!stylesheet instanceof _Map) throw new Error('' + stylesheet + ' should be a Map'); | ||
if (!(stylesheet instanceof _Map)) throw new Error('' + stylesheet + ' should be a Map'); | ||
@@ -168,2 +171,1 @@ return _Object$keys(styles).reduce(function (acc, key) { | ||
}; | ||
module.exports = exports['default']; |
@@ -11,5 +11,7 @@ import { | ||
export const StylesheetMap = Map; | ||
export default { | ||
create( styles, stylesheet = globalStylesheet ) { | ||
if ( !stylesheet instanceof Map ) throw new Error(`${ stylesheet } should be a Map`); | ||
if ( !(stylesheet instanceof Map) ) throw new Error(`${ stylesheet } should be a Map`); | ||
@@ -16,0 +18,0 @@ return Object.keys( styles ).reduce( ( acc, key ) => { |
{ | ||
"name": "stilr", | ||
"version": "1.1.0", | ||
"version": "1.2.0", | ||
"description": "Encapsulated styling for your javascript components with all the power of javascript and CSS combined. Usefull with React", | ||
@@ -5,0 +5,0 @@ "main": "dist", |
@@ -1,2 +0,2 @@ | ||
# Stilr [![Build Status](https://travis-ci.org/chriskjaer/stilr.svg)](https://travis-ci.org/chriskjaer/stilr) [![npm version](https://badge.fury.io/js/stilr.svg)](http://badge.fury.io/js/stilr) | ||
# Stilr [![Build Status](https://travis-ci.org/kodyl/stilr.svg)](https://travis-ci.org/kodyl/stilr) [![npm version](https://badge.fury.io/js/stilr.svg)](http://badge.fury.io/js/stilr) | ||
@@ -3,0 +3,0 @@ Encapsulated styling for your javascript components with all the power of |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
27504
400