Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
routes.forEach((value) => {
const matchTest = matchPath(value.get('path'), pathArray)
const matchAlias = matchPath(value.get('alias'), pathArray)
if (matchTest.matched || matchAlias.matched) {
const routeParams = matchTest.routeParams
// Extract common paths from URL
if (value.has('extractPaths') && value.get('extractPaths')) {
const domainPathLocation = pathArray.indexOf(ConfGlobal.domain)
const dialectPathLocation = 5
const languagePathLocation = 4
const languageFamilyPathLocation = 3
// If domain is specified in the URL, these are Nuxeo paths that can be extracted
if (domainPathLocation !== -1) {
// Path from domain to end of path (e.g. /FV/Workspaces/Data/family/language/dialect)
const nuxeoPath = pathArray.slice(domainPathLocation, pathArray.length)
routes.forEach((value) => {
const matchTest = matchPath(value.get('path'), pathArray)
const matchAlias = matchPath(value.get('alias'), pathArray)
if (matchTest.matched || matchAlias.matched) {
const routeParams = matchTest.routeParams
// Extract common paths from URL
if (value.has('extractPaths') && value.get('extractPaths')) {
const domainPathLocation = pathArray.indexOf(ConfGlobal.domain)
const dialectPathLocation = 5
const languagePathLocation = 4
const languageFamilyPathLocation = 3
// If domain is specified in the URL, these are Nuxeo paths that can be extracted
if (domainPathLocation !== -1) {
// Path from domain to end of path (e.g. /FV/Workspaces/Data/family/language/dialect)
const nuxeoPath = pathArray.slice(domainPathLocation, pathArray.length)
routes.forEach((value) => {
// PSUEDO: compare route path with breadcrumb path
const matchTest = matchPath(value.get('path'), [splitPathItem])
if (matchTest.matched) {
/* PSUEDO: A route entry can have a `redirects` prop that will be used to update `hrefPath`
eg:
redirects: [{
condition: ({
props: {computeLogin, splitWindowPath}
})=>{},
target: ({
props: {splitWindowPath}
})=>{}
}],
*/
if (value.has('redirects')) {
value.get('redirects').forEach((redirectValue) => {