0.0.3 • Published 2 years ago

@matthewp/reactive-vt-router v0.0.3

Weekly downloads
-
License
BSD-3-Clause
Repository
-
Last release
2 years ago

@matthewp/reactive-vt-router

Usage:

The basis is the fromNavigation observable which listens for navigate events. Pipe this into the handle function which does the rest.

import { fromNavigate, handle } from '@matthewp/reactive-vt-router';

fromNavigate()
.pipe(
  handle()
)
.subscribe();

For full control don't use handle, but instead use each part. You can swap out the parts you don't need (for example remove fetch and swap and put your own DOM update where swap was).

import {
  fromNavigate, intercept, fetch, startViewTransition, swap
} from '@matthewp/reactive-vt-router';

fromNavigate()
.pipe(
  intercept(),
  fetch(),
  startViewTransition(),
  swap(),
)
.subscribe();
0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago