Skip to content
This repository was archived by the owner on Jun 26, 2025. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions COMPARE.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# How much tinro adds to your bandle?
# How much tinro adds to your bundle?

Current tinro value is **6.43 Kb** (2.57 Kb gzipped)

## Comparsion
## Comparison

* bundle.js with tinro inside: **33.87 Kb** (10.34 Kb gzipped)
* bundle.js with mocked tinro : **27.44 Kb** (7.77 Kb gzipped)

## How do we compare?

Comparsion made by building [testing app](https://github.com/AlexxNB/tinro/tree/master/tests) in production mode two times. First one with tinro letest version inside. In the second case - all imports from tinro are mocked by empty exports.
Comparison made by building [testing app](https://github.com/AlexxNB/tinro/tree/master/tests) in production mode two times. First one with tinro latest version inside. In the second case - all imports from tinro are mocked by empty exports.

8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ You can import the `router` object from the `tinro` package:
Programmatically change the URL of the current page.

### `router.mode`
Methods to change curent router mode:
Methods to change current router mode:

* `history()` - set HistoryAPI navigation method
* `hash()` - set hash navigation method
Expand Down Expand Up @@ -474,7 +474,7 @@ Deprecated. See `router.meta` instead.

## Recipes

tinro is not the most powerful router among all those available for Svelte applications. We prefer a smaller footprint in your bundles over having all possible features out of the box. But you can easily code some features yourself using the recipies below:
tinro is not the most powerful router among all those available for Svelte applications. We prefer a smaller footprint in your bundles over having all possible features out of the box. But you can easily code some features yourself using the recipes below:

### Lazy loading components

Expand Down Expand Up @@ -505,7 +505,7 @@ And use it when you need a lazy loaded component in your routes:

### Transitions

If you want a transiton when the path changes, create a component like this:
If you want a transition when the path changes, create a component like this:

```html
<!-- Transition.svelte -->
Expand Down Expand Up @@ -598,7 +598,7 @@ Then place this component somewhere in your `App.svelte` root file:

## Troubleshooting

If you use Vite to bandle your app (including SvelteKit), you should exclude `tinro` from the `optimizedDeps` in Vite's config:
If you use Vite to bundle your app (including SvelteKit), you should exclude `tinro` from the `optimizedDeps` in Vite's config:

```javascript
...
Expand Down