neetjn / riot-routing

Lightweight client sided router for Riot.js.
MIT License
3 stars 0 forks source link

0.0.1 Roadmap #1

Closed neetjn closed 4 years ago

neetjn commented 5 years ago

After thoughtful consideration, I've decided to drop the [riot-view-router]() project and start from scratch. Riot.js 4 is a complete overhaul of the framework, with a fundamentally different api. My initial observations can be read here.

Roadmap - 0.0.1

neetjn commented 5 years ago

See: core-routing for router interface. Once version 0.0.1 is feature completed and tested, I'll begin drafting a road map for riot-routing.

neetjn commented 5 years ago

Update (9/2/19):

neetjn commented 5 years ago

Update (9/11/19):

neetjn commented 5 years ago

Update (9/27/19):

neetjn commented 5 years ago

Update (9/28/19):

root.riot

<Root>
  <router routes={ routes } />
  <script>
    import Router from 'riot-routing/router.riot'
    import Home from './components/home.riot'
    import NotFound from './component/not-found.riot'

    const routes = [
      { component: Home, path: ['/', '/home'] },
      { component: NotFound, path: '*' }
    ]

    export default {
      routes,
      components: {
        Router
      }
    }
  </script>
</Root>

router.riot

<Router>
  <route each={ route in props.routes } if={ route.active } />
</Router>

route.riot

TBD