Comments (5)
So the issue was with previous versions and a configuration option missed in tsConfig.json
.
Correct way to import with require
is:
const { Path } = require('path-parser')
// or
const Path = require('path-parser').default
from path-parser.
Great! Thanks for clarifying and updating the README 😉
Again, amazing work!
from path-parser.
Two questions:
- By new version, do you mean 4.0.x? (i.e not the latest patch)
- How do you import
Path
? ES imports or commonJS require?
from path-parser.
-
I'm not entirely sure, I just installed the one that came from running
npm i --save path-parser
which apparently is[email protected]
-
const Path = require('path-parser');
from path-parser.
Ah, that's weird: 59f43c5 🤔
I added a named export, and it caused rollup to compile the default export from module.exports = Path
to module.exports.default = Path
. Not sure if it is an issue with Rollup or TypeScript
from path-parser.
Related Issues (20)
- Hash part of an URL HOT 1
- Percent encoding support for URL path HOT 8
- Feature: Optional parameter HOT 2
- Support for curly brackets url syntax HOT 1
- After V4.0.2 Path is broken HOT 2
- Plus not allowed in path param HOT 1
- Support for `==` in parameters HOT 3
- does not match url parameter with @ symbol HOT 1
- Better type definition for `TestMatch` HOT 1
- TypeError: PathParser is not a constructor HOT 1
- Case insensitive query parameters names HOT 1
- Double encoding or no encoding
- [REQ] Add constraints to query params as well HOT 1
- Err: cannot find module 'tslib' HOT 1
- Incorrect results when using regex in path HOT 1
- Path.test fails to match when query params are omitted
- Option to treat plus signs (+) as spaces
- Optional param HOT 1
- Unexpected behavior of partialTest HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from path-parser.