-
Notifications
You must be signed in to change notification settings - Fork 9
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
addButton is not a function #1353
Comments
From which version of @nextcloud/dialogs is it possible to use |
It if from v 4.2.0 whereas Picker app is still using 3.1.2 which is the reason of this error.
However, even if I add With
works, but with
doesn't work, and even
doesn't work. I get the following error:
|
The FilePicker was added with version 4.2 so you need to use 4.2+ (or version 5 or later if you target Nextcloud 28+). With versions before 4.2 you can only use some limited functions. For your error:
How do you bundle your app? This looks like you somehow include CSS imports in your final bundle which does not work for browsers but you have to either extract CSS to a file or inject inline (webpack or vite plugin). |
Thank you @susnux for coming back to me. I'm trying to improve this app : https://github.com/nextcloud/picker Here is my work : https://github.com/Thatoo/picker/blob/ClipboardOnly/src/main.js |
@susnux I ask that because now I get these error in my web browser consol :
|
If I add |
Vue 2 is required then, others are dependencies and will be installed as needed.
That plugin is simply broken, I think you can disable that ESLint plugin, the issue is open for a looong time: |
Could you tell me how to disable import/no-unresolved eslint plugin? In other word, how should I modify https://github.com/nextcloud/picker/blob/main/.eslintrc.js ? |
I found it. I needed to add Now I have a prettier window thanks to css but it doesn't display files and I keep having errors in console listed earlier
from nextcloud/picker#42 |
I wonder, are nextcloud/dialogs v4.2 and nextcloud/vue v7.12 working on nextcloud v28? |
I tried with the latest release @nextcloud/dialogs v 5.3.5 and @nextcloud/vue v 8.15.0, and it fully works! |
works!
However, if I modify it to
then it's not working and I get the following error in console :
Uncaught TypeError: _nextcloud_dialogs__WEBPACK_IMPORTED_MODULE_4__.getFilePickerBuilder(...).allowDirectories(...).setMultiSelect(...).addButton is not a function
Is this Readme wrong https://github.com/nextcloud-libraries/nextcloud-dialogs?tab=readme-ov-file#use-the-filepickerbuilder ?
The text was updated successfully, but these errors were encountered: