# How to match all routes under /xyz/\*

**URL:** <https://discuss.emberjs.com/t/how-to-match-all-routes-under-xyz/18160>\
**Category:** Routing\
**Created:** [August 24, 2020, 12:59pm UTC](https://discuss.emberjs.com/t/how-to-match-all-routes-under-xyz/18160 "2020-08-24T12:59:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ondrejsevcik](https://avatars.discourse-cdn.com/v4/letter/o/ed655f/32.png) [@ondrejsevcik](https://discuss.emberjs.com/u/ondrejsevcik)\
**Post date:** [August 24, 2020, 12:59pm UTC](https://discuss.emberjs.com/t/how-to-match-all-routes-under-xyz/18160/1 "2020-08-24T12:59:08Z")

</div>

Hi,

I’m trying to integrate React into existing Ember app and I would like to have a dedicated route in the ember app where the React is instantiated and then it is not touched by Ember.

I have one template in `app/routes/react-route.hbs` and then I’ve defined this in the router.js

```auto
Router.map(function() {
  this.route('react-route');
});

```

The problem is that once some of the sub-routes are accessed, it fails with error. I would need somehow to tell ember that all of those

```nohighlight
/react-route
/react-route?queryParam=10
/react-route/another-subroute
/react-route/...

```

should go to the `react-route.hbs` template. Also when transitioning from `/react-route/a` to `/react-route/b` it should not care.

Is this possible with ember router?

---

<div class="post-metadata">

**Author:** ![dknutsen](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/dknutsen/32/16471_2.png) [@dknutsen](https://discuss.emberjs.com/u/dknutsen)\
**Post date:** [August 24, 2020, 2:23pm UTC](https://discuss.emberjs.com/t/how-to-match-all-routes-under-xyz/18160/2 "2020-08-24T14:23:50Z")

</div>

Ember supports [wildcard/glob routes](https://guides.emberjs.com/release/routing/defining-your-routes/#toc_wildcard--globbing-routes) so maybe you could try something like

```auto
  this.route('react-route', { path: '/reacty/*' });

```

---

<div class="post-metadata">

**Author:** ![ondrejsevcik](https://avatars.discourse-cdn.com/v4/letter/o/ed655f/32.png) [@ondrejsevcik](https://discuss.emberjs.com/u/ondrejsevcik)\
**Post date:** [August 25, 2020, 7:15am UTC](https://discuss.emberjs.com/t/how-to-match-all-routes-under-xyz/18160/3 "2020-08-25T07:15:42Z")

</div>

sadly none of these work

```auto
this.route('react-route', { path: '/react-route/*' });

// or 
this.route('react-route', function () {
  this.route('index', { path: '/*path'});
});

// or
this.route('react-route', { path: '/react-route/*path' });

```

all of them fail with UnrecognizedURLError.

From the [guides](https://guides.emberjs.com/release/routing/defining-your-routes/), it’s not really clear how to construct such a route. I can’t use catch-all route because I still want to have a 404 route in my app.
