I have successfully run superbase with svelte using this tutorial . However I really need the sveltkit rather than basing it on the svelte template . When I try to use superbase based on a sveltkit project I get the following error
11:50:01 [vite] Error when evaluating SSR module /src/superbaseClient.js:
ReferenceError: __api is not defined
at /src/superbaseClient.js:3:21
at async instantiateModule (/Users/bob/Documents/dev/javascript/svelte/svelteBp/node_modules/vite/dist/node/chunks/dep-971d9e33.js:56177:9)
11:50:01 [vite] Error when evaluating SSR module /src/routes/sbase.svelte:
ReferenceError: __api is not defined
at /src/superbaseClient.js:3:21
at async instantiateModule (/Users/bob/Documents/dev/javascript/svelte/svelteBp/node_modules/vite/dist/node/chunks/dep-971d9e33.js:56177:9)
__api is not defined
ReferenceError: __api is not defined
at /src/superbaseClient.js:3:21
at async instantiateModule (/Users/bob/Documents/dev/javascript/svelte/svelteBp/node_modules/vite/dist/node/chunks/dep-971d9e33.js:56177:9)
I have tried
Created a new sveltkit project using the sveltkit getting started instructions
Followed the getting started instructions in superbase but replaced the use of the svelte template with a sveltekit project.
Installed superbase with https://github.com/supabase-community/svelte-supabase
I ignored the lines about installing the rollup plugins in the guide because I believe they are covered off by svelte kit.
More code is available for the whole project on the github. The code with all my failed attempts at getting it to work can be found in a branch on that repo called "add superbase"
You can try the Supabase Adder: https://github.com/supabase-community/svelte-supabase
Related
I am trying to integrate PruneCluster for Leaflet into my Webpack configuration, and I’m doing exactly what’s in the Readme https://github.com/SINTEF-9012/PruneCluster#webpack--npm
But I keep getting this error
Module build failed (from ./node_modules/exports-loader/dist/cjs.js):
TypeError: this.getOptions is not a function
at Object.loader (/Users/username/Documents/Repository/project-name/web/app/themes/project-name/node_modules/exports-loader/dist/index.js:23:24)
Are there any dependencies I am missing or do I need some form of config file?
I'm using Vue JS to build a plugin and am using the p11n module. I've built my components and everything works fine when serving via npm run serve, but when trying to build the project via npm run build which essentially is running: vue-cli-service build I get the following error regardless of what version I use:
ERROR Error: Unexpected token (Note that you need plugins to import files that are not JavaScript)
Error: Unexpected token (Note that you need plugins to import files that are not JavaScript)
at error (/Applications/MAMP/htdocs/application-compiler-gui/node_modules/rollup/dist/shared/node-entry.js:5400:30)
at Module.error (/Applications/MAMP/htdocs/application-compiler-gui/node_modules/rollup/dist/shared/node-entry.js:9824:16)
at tryParse (/Applications/MAMP/htdocs/application-compiler-gui/node_modules/rollup/dist/shared/node-entry.js:9717:23)
at Module.setSource (/Applications/MAMP/htdocs/application-compiler-gui/node_modules/rollup/dist/shared/node-entry.js:10080:33)
at Promise.resolve.catch.then.then.then (/Applications/MAMP/htdocs/application-compiler-gui/node_modules/rollup/dist/shared/node-entry.js:12366:20)
No idea how to fix this, I've tried installing the Vue JS rollup plugin, no luck :(
I tried to create a nuxt app with the guide from the official website, chose default options because I wanted the starter template but on running npm run dev, I keep encountering the error:
This relative module was not found:
* ./components/nuxt-error.vue in ./.nuxt/index.js
I've tried searching about it but I couldn't find any useful resource/fix. I've also tried vue init nuxt-community/starter-template for the installation but I still get the same error.
Any fixes?
So I found a solution. I couldn’t figure out the error because the nuxt-error.vue file was actually imported correctly. Turns out “npm” installations have been giving me issues (had issues with TailwindCSS too).
So if you ever encounter this error on loading the base nuxt app, recreate the project using “yarn” instead. Works like magic!
This Error basically means, that in one of your files you are trying to import another file with the relative path of ./components/nuxt-error.vue but no file with this path exists.
However
I just read that vue init nuxt-community/starter-template is deprecated and no longer maintained. Instead of fixing this Error you should restart your project with npx create-nuxt-app <yourAppName>. https://github.com/nuxt-community/starter-template
Trying to use #angular/flex-layout in an existing npm-enabled Ionic 3 project.
Adding "FlexLayoutModule" to my main module's imports won't allow the app to start, saying that: cannot find module "rxjs/operators" is the cause.
Already cleared node_module, npm install, reinstalled Ionic CLI. Nothing helps. Could it be a version conflict? Moreover, I'm already using Observables in this project. I don't get it. And the import of "FlexLayoutModule" is in cause of this issue (disabling the import removes the issue).
Anyone could be successful at using flex-layout with ionic? I've seen this plunk, but it uses system.js, so not 100% reproducing my goal.
http://plnkr.co/edit/y8R0MF?p=info
Edit: a more verbose issue:
Uncaught (in promise): Error: Cannot find module "rxjs/operators"
Error: Cannot find module "rxjs/operators" at Object.580
(http://localhost:8100/build/22.main.js:319:7) at webpack_require
(http://localhost:8100/build/main.js:48:30) at Object.1021
(http://localhost:8100/build/22.main.js:11:79) at webpack_require
(http://localhost:8100/build/main.js:48:30) at
http://localhost:8100/build/main.js:122015:10 at t.invoke
(http://localhost:8100/build/polyfills.js:3:9283) at Object.onInvoke
(http://localhost:8100/build/main.js:4650:37) at t.invoke
(http://localhost:8100/build/polyfills.js:3:9223) at r.run
(http://localhost:8100/build/polyfills.js:3:4452) at
http://localhost:8100/build/polyfills.js:3:14076
I'm getting a similar error with Angular CLI. Everything is OK until I include FlexLayoutModule in the app's NgModule imports. Then I get the error:
Module not found: Error: Can't resolve 'rxjs/operators' in 'D:\dev\Vms.Signup.Client\node_modules\#angular\flex-layout\esm5'
I updated to the latest rxjs and that seems to have fixed it.
I would like to use this module on my Titanium project : https://github.com/AppWerft/TiJSPDF
To install, I have just copied the folder 'modules' in my project and I have added it in tiapp.xml.
When I try to use it :
require('ti.jspdf');
var doc = new jsPDF();
I get the following error :
- Message: Uncaught ReferenceError: jsPDF is not defined
I think I don't use this module correctly. Can you help me, please ?
Since this is a javascript module and not a compiled module, put it in the app/lib folder of your alloy project. See the documentation on Javascript modules here: http://docs.appcelerator.com/platform/latest/#!/guide/CommonJS_Modules_in_Titanium-section-src-29004791_CommonJSModulesinTitanium-JavaScriptModules