Skip to content
This repository has been archived by the owner on Jul 21, 2021. It is now read-only.

Update to vue-router v4 styles #10

Open
Shyam-Chen opened this issue Jan 18, 2021 · 4 comments
Open

Update to vue-router v4 styles #10

Shyam-Chen opened this issue Jan 18, 2021 · 4 comments
Labels
api-change enhancement New feature or request

Comments

@Shyam-Chen
Copy link

Ref: https://next.router.vuejs.org/guide/migration/

@lyohaplotinka
Copy link
Collaborator

@Shyam-Chen, thank you for the reference.
Why do you think it is worth doing this? Easyroute is not meant to be a "vue-router clone", it just provides an API in vue-router style (similar to the previous version, apparently). Personally, this is much more convenient for me :)

Thank you!

@Shyam-Chen
Copy link
Author

Shyam-Chen commented Jan 18, 2021

Maybe I think that the code is used for friendly tree shaking. You don't need to write more if and switch in easyroute-core to check the mode.

import { createRouter, createWebHistory } from 'vue-router';

createRouter({
  history: createWebHistory('/base'),
  routes: [...],
});

@lyohaplotinka
Copy link
Collaborator

@Shyam-Chen, nice idea. I will try to think about how best to implement this without breaking backward compatibility.
If you have your vision, feel free to contribute easyroute-core!

@lyohaplotinka lyohaplotinka transferred this issue from easyroute-router/svelte-easyroute Jan 18, 2021
@lyohaplotinka lyohaplotinka added api-change enhancement New feature or request labels Jan 18, 2021
@Shyam-Chen
Copy link
Author

Although the repository is awesome, you should enhance APIs and documents first. Therefore, these breaking changes should be postponed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api-change enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants