Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 [Bug]: After initializing the project, the official website button and alert components are introduced, and the front-end defined (reading 'tiny_mode') is reported. " #141

Closed
lipan007 opened this issue Apr 16, 2023 · 10 comments
Labels
bug Something isn't working

Comments

@lipan007
Copy link

Version

`-- @opentiny/vue@2.6.1

Vue Version

2.6.10

Link to minimal reproduction

e.runtime.esm.js:4605 [Vue warn]: inject() can only be used inside setup() or functional components.

found in

--->

at src/views/Home.vue
at src/App.vue

ue warn]: Error in setup: "TypeError: Cannot read properties of undefined (reading 'tiny_mode')"

found in

--->

at src/views/Home.vue
at src/App.vue

peError: Cannot read properties of undefined (reading 'tiny_mode')
ue warn]: Error in data(): "TypeError: Cannot read properties of undefined (reading 'length')"

found in

--->

at src/views/Home.vue
at src/App.vue

e.runtime.esm.js:4605 [Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'buttonDisabled')"

found in

--->

at src/views/Home.vue
at src/App.vue

e.runtime.esm.js:4605 [Vue warn]: inject() can only be used inside setup() or functional components.

found in

--->

at src/views/Home.vue
at src/App.vue

Step to reproduce

vuecli 初始化项目
安装 tiny
引入官网例子

What is expected

No response

What is actually happening

No response

Any additional comments (optional)

No response

@kagol kagol added the bug Something isn't working label Apr 17, 2023
@kagol
Copy link
Member

kagol commented Apr 17, 2023

@lipan007 先将 vue 版本固定为 2.6.14 试试看呢?我们来看下这个问题

@acyza
Copy link
Contributor

acyza commented Apr 17, 2023

我把版本固定到2.6.14之后,button还是报相同的错误,alert弹窗文本确实没有了 uTools_1681717448133

你打开node_modules文件夹看看安装的vue版本是不是2.6,我试了2.6.10和2.6.14都没报错。

@acyza
Copy link
Contributor

acyza commented Apr 17, 2023

2.7会报错,好像是因为2.7不支持composition-api

@lipan007
Copy link
Author

好了,我把版本固定之后,没有报错了,谢谢

@acyza
Copy link
Contributor

acyza commented Apr 17, 2023

@kagol 我看vue-common的adapter文件夹里有个vue2.7的文件夹,是有针对vue2.7单独的版本吗?

@lipan007
Copy link
Author

tinycli后续会支持vue2么

@kagol
Copy link
Member

kagol commented Apr 17, 2023

@kagol 我看vue-common的adapter文件夹里有个vue2.7的文件夹,是有针对vue2.7单独的版本吗?

是的哈~不过现在还没有发布 2.7 版本,后续有计划发布 2.7 版本,这样业务如果使用 vue2.7 就可以安装 @opentiny/vue@2.7 啦

@kagol
Copy link
Member

kagol commented Apr 17, 2023

tinycli后续会支持vue2么

麻烦在这里提交一个 issue 哈
https://github.com/opentiny/tiny-cli/issues

@kagol kagol changed the title 🐛 [Bug]: 初始化项目后,引入官网button和alert组件,前端报错defined (reading 'tiny_mode')" 🐛 [Bug]: After initializing the project, the official website button and alert components are introduced, and the front-end defined (reading 'tiny_mode') is reported. " Aug 2, 2023
@kagol
Copy link
Member

kagol commented Oct 19, 2023

@kagol 我看vue-common的adapter文件夹里有个vue2.7的文件夹,是有针对vue2.7单独的版本吗?

vue2.7已支持,目前已发布 alpha 版本:@opentiny/vue@2.11.0-alpha.2

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


@kagol I see that there is a vue2.7 folder in the adapter folder of vue-common. Is there a separate version for vue2.7?

vue2.7 is supported, and the alpha version has been released: @opentiny/vue@2.11.0-alpha.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants