Route.register() not a function

Hi all,

using node.js and copying the following from the examples returns
“TypeError: route.register is not a function”

Any hints what is missing. Everything else in my application works flawlessly and this is the last bit missing :slight_smile:

import DefineMap from “can-define/map/map”;
import route from “can-route/can-route”;

const AppViewModel = DefineMap.extend( {
page: “string”
} );
const appState = new AppViewModel(); = appState;
route.register( “{page}”, { page: “home” } );



Which version of can-route are you using?

package.json tells me

“_id”: “can-route@3.0.11”,

register is part of 4.0. You need to upgrade that dependency.

Thx, did not think about that possibility