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

cson

Package Overview
Dependencies
Maintainers
1
Versions
113
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cson - npm Package Compare versions

Comparing version 1.6.0 to 1.6.1

18

out/lib/cson.js
// Generated by CoffeeScript 1.7.1
(function() {
var CSON, ambi, coffee, extractOpts, fsUtil, js2coffee, pathUtil, requireFreshSafe, wait;
var CSON, ambi, coffee, extractOpts, fsUtil, isJsOrCoffee, isJsonOrCson, js2coffee, pathUtil, requireFreshSafe, wait;

@@ -25,2 +25,10 @@ coffee = require('coffee-script');

isJsOrCoffee = function(filePath) {
return /\.(js|coffee)$/.test(filePath);
};
isJsonOrCson = function(filePath) {
return /\.(json|cson)$/.test(filePath);
};
CSON = {

@@ -31,5 +39,5 @@ parseFile: function(filePath, opts, next) {

filePath = pathUtil.resolve(filePath);
if (/\.(js|coffee)$/.test(filePath)) {
if (isJsOrCoffee(filePath)) {
requireFreshSafe(filePath, next);
} else if (/\.(json|cson)$/.test(filePath)) {
} else if (isJsonOrCson(filePath)) {
fsUtil.readFile(filePath, (function(_this) {

@@ -56,3 +64,3 @@ return function(err, data) {

filePath = pathUtil.resolve(filePath);
if (/\.(js|coffee)$/.test(filePath)) {
if (isJsOrCoffee(filePath)) {
try {

@@ -64,3 +72,3 @@ return result = requireFreshSafe(filePath);

}
} else if (/\.(json|cson)$/.test(filePath)) {
} else if (isJsonOrCson(filePath)) {
data = fsUtil.readFileSync(filePath);

@@ -67,0 +75,0 @@ opts.filename = filePath;

{
"title": "CSON",
"name": "cson",
"version": "1.6.0",
"description": "CoffeeScript-Object-Notation Parser. Same as JSON but for CoffeeScript objects",
"version": "1.6.1",
"description": "CoffeeScript-Object-Notation Parser. Same as JSON but for CoffeeScript objects.",
"homepage": "https://github.com/bevry/cson",

@@ -43,2 +43,3 @@ "license": {

"Ryan LeFevre <meltingice8917@gmail.com> (https://github.com/meltingice)",
"Zearin (https://github.com/Zearin)",
"Zhang Cheng <czhang.oss@gmail.com> (https://github.com/zhangcheng)"

@@ -60,3 +61,3 @@ ],

"extract-opts": "~2.2.0",
"js2coffee": "~0.3.0",
"js2coffee": "~0.3.1",
"requirefresh": "~1.1.2"

@@ -66,5 +67,5 @@ },

"chai": "~1.9.0",
"joe": "~1.3.0",
"joe": "~1.5.0",
"joe-reporter-console": "~1.2.1",
"projectz": "~0.3.10"
"projectz": "~0.3.15"
},

@@ -71,0 +72,0 @@ "directories": {

@@ -186,2 +186,3 @@ <!-- TITLE/ -->

- [Ryan LeFevre](https://github.com/meltingice) <meltingice8917@gmail.com> — [view contributions](https://github.com/bevry/cson/commits?author=meltingice)
- [Zearin](https://github.com/Zearin) — [view contributions](https://github.com/bevry/cson/commits?author=Zearin)
- [Zhang Cheng](https://github.com/zhangcheng) <czhang.oss@gmail.com> — [view contributions](https://github.com/bevry/cson/commits?author=zhangcheng)

@@ -188,0 +189,0 @@

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