Skip to content
This repository has been archived by the owner on Oct 28, 2022. It is now read-only.

With Vue3 by cdn I need to use app.use(VueNextRx) instead #24

Closed
Thaina opened this issue May 11, 2022 · 2 comments
Closed

With Vue3 by cdn I need to use app.use(VueNextRx) instead #24

Thaina opened this issue May 11, 2022 · 2 comments
Assignees

Comments

@Thaina
Copy link

Thaina commented May 11, 2022

Describe the bug
VueRX is not really defined in this package and it not really register into vue. However there was global.VueNextRX defined

I think it's because vue3 change pattern into Vue.createApp then using app.use before app.mount

And so with this pattern. I need to use app.use(VueNextRx)

To Reproduce

  1. use these package by cdn
		<script src="https://unpkg.com/vue@3"></script>
		<script src="https://unpkg.com/vue-router@4"></script>
		<script src="https://unpkg.com/rxjs@7/dist/bundles/rxjs.umd.min.js"></script>

		<script src="https://cdn.jsdelivr.net/npm/@nopr3d/vue-next-rx@1.0/dist/vue-next-rx.min.js"></script>
  1. In js use var app = Vue.createApp({ subscriptions() { return { ... } } });
    2.1. If just use app.mount the subscriptions will not be called
    2.2. If use app.use(VueRx) it throw undefined VueRX error

Expected behavior

using app.use(VueNextRx) instead work normally as expected

Desktop (please complete the following information):

  • OS: Windows
  • Browser: chrome

Additional context

If I am correct the readme document should properly mention this behaviour

@github-actions
Copy link

Hi ! Thanks for this issue, i will look at it quickly !' first issue

@NOPR9D NOPR9D self-assigned this May 25, 2022
@NOPR9D
Copy link
Member

NOPR9D commented May 25, 2022

Yeah, my bad... At the html file who sevre as exemple i use VueNextRx, so it's a mistake with the readme...

Sorry !

But thanks for your issue ! I change that !

@NOPR9D NOPR9D closed this as completed May 25, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants