Détail du package

join-path-js

chilijung3.5kMIT0.0.0

Simple path join and dirname functions for generic javascript

path, js, join

readme

join-path

Simple path join and dirname functions for generic javascript, a small package of this gist, big thank to @creationix.

Why

Nodejs have buildin some great url manipulation, but native javascript don't. Use this package with browserify, to make url manipulation in frontend possible.

Install

npm install join-path-js

Sample

var assert = require('assert');
var join = require('join-path');

it("should join the path", function() {
  assert.equal('/test/wow/this/is/awesome', join('/test/', './wow/this/is/awesome'))
})

License

MIT