Skip to content

Commit

Permalink
Updated regexparam dep to 2.0.0
Browse files Browse the repository at this point in the history
Fixes #220
  • Loading branch information
ItalyPaleAle authored Jun 16, 2021
1 parent b6afbae commit 69c226d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Router.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ function scrollstateHistoryHandler(event) {

<script>
import {createEventDispatcher, afterUpdate} from 'svelte'
import regexparam from 'regexparam'
import {parse} from 'regexparam'
/**
* Dictionary of all routes, in the format `'/path': component`.
Expand Down Expand Up @@ -274,7 +274,7 @@ class RouteItem {
throw Error('Invalid value for "path" argument - strings must start with / or *')
}
const {pattern, keys} = regexparam(path)
const {pattern, keys} = parse(path)
this.path = path
Expand Down
4 changes: 2 additions & 2 deletions active.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import regexparam from 'regexparam'
import {parse} from 'regexparam'
import {loc} from './Router.svelte'

// List of nodes to update
Expand Down Expand Up @@ -86,7 +86,7 @@ export default function active(node, opts) {

// If path is not a regular expression already, make it
const {pattern} = typeof opts.path == 'string' ?
regexparam(opts.path) :
parse(opts.path) :
{pattern: opts.path}

// Add the node to the list
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
},
"homepage": "https://github.com/ItalyPaleAle/svelte-spa-router#readme",
"dependencies": {
"regexparam": "1.3.0"
"regexparam": "2.0.0"
},
"devDependencies": {
"@rollup/plugin-commonjs": "^19.0.0",
Expand Down

0 comments on commit 69c226d

Please sign in to comment.