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

easypathutil

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

easypathutil - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "easypathutil",
"version": "1.0.1",
"version": "1.0.2",
"description": "Fluent filepaths, made simple.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -29,6 +29,9 @@ <div align="center">

### Goals/Why use Easypathutil
• This package hopes to make your paths easier to follow for deeply nested files.
• Easily check for existence of a file or folder, read, get stats, or require.
### Goals/Why use Easypathutil
This package hopes to make your paths easier to follow for deeply nested files.
• Lightweight: Package size is around 6kB
The tutorial below aims to demonstrate the core functionality of this package.

@@ -42,5 +45,5 @@

const file = require('fs').readFileSync(require('path').join(\_\_dirname, '../../../../data/users.json'));
const file = require('fs').readFileSync(require('path').join(__dirname, '../../../../data/users.json'));
const json = JSON.parse(file);
const default_object = new (require(require('path').join(\_\_dirname, '../../../../classes/A')).default);
const default_object = new (require(require('path').join(__dirname, '../../../../classes/A')).default);

@@ -100,3 +103,3 @@ **After:**

// optional "." or "\_" and case insensitive
// optional "." or "_" and case insensitive
myjsfile.$read_file, myjsfile.$read_file_sync

@@ -118,3 +121,3 @@ myjsfile.$readfile, myjsfile.$readfile_sync

const jsonfile = myfolder('jsonfile.json'); // Points to /root/home/projects/myfolder/jsonfile.json
const parsedjson = jsonfile.$json // Aliases: .$json, .$toJson, .$JSON, .$to_json, etc, optional "." or "\_" and case insensitive
const parsedjson = jsonfile.$json // Aliases: .$json, .$toJson, .$JSON, .$to_json, etc, optional "." or "_" and case insensitive

@@ -161,1 +164,4 @@ **New object shortcut (.$new, .$new_default)**

This package adapts as needs arise, and although it has been tested on some versions of node v8 and v10, problems may still occur.
Enjoy this package? Consider starring on [github](https://github.com/wzhouwzhou/easypathutil) and checking out some of my other work:
[Youtube Search API](https://npmjs.com/ytsearcher)
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