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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

iles using a named export from vue/transformer-sfc that does not exist #266

Open
2 tasks done
jmegs opened this issue Jan 12, 2024 · 6 comments
Open
2 tasks done

Comments

@jmegs
Copy link

jmegs commented Jan 12, 2024

Description 馃摉

iles using a named export from vue/transformer-sfc that does not exist

Dependencies Info
iles v0.9.5 | vite v4.5.1

- iles@0.9.5
- typescript@5.3.3
- vue-tsc@1.8.27

Logs 馃摐

If not providing a reproduction:

Output
$ DEBUG=iles:* npm run dev

> iles-app@0.0.0 dev
> iles dev --open

file:///Users/jmeguerian/Code/tmp/iles-app/node_modules/iles/dist/node/chunk-IMB7AIW2.js:63
import { shouldTransformRef, transformRef } from "vue/compiler-sfc";
                             ^^^^^^^^^^^^
SyntaxError: The requested module 'vue/compiler-sfc' does not provide an export named 'transformRef'
    at ModuleJob._instantiate (node:internal/modules/esm/module_job:132:21)
    at async ModuleJob.run (node:internal/modules/esm/module_job:214:5)
    at async ModuleLoader.import (node:internal/modules/esm/loader:329:24)
    at async executeCommand (file:///Users/jmeguerian/Code/tmp/iles-app/node_modules/iles/dist/node/cli.js:25:30)

Node.js v21.1.0
@ohuu
Copy link

ohuu commented Jan 21, 2024

I'm seeing the same thing.

@ohuu
Copy link

ohuu commented Jan 21, 2024

It looks like transformRef was removed in vue 3.4. See line 15 here

My nasty hack of a workaround is to fiddle my package-lock to force vue 3.3.

It seems from this commit (lines 73-78) that shouldTransformRef is hardcoded to return false, suggesting that this functionality is no longer needed and we can remove all references to transformRef in iles?

@ElMassimo
Copy link
Owner

Thanks for reporting, I'll remove usage of transformRef in the next release.


The reactivityTransform proposal has been removed in Vue 3.4, but it's usable through a third-party plugin.

I think the reactivity transform remains a nicer dialect when using script setup, especially once Vue introduced the ability for watch to receive a getter, which addressed some of the DX concerns such as having to use $$().

However, it's better to let the user make that decision on their own (custom Vite plugins can be added easily in iles.config.ts).

@therealshark
Copy link

Do you have an ETA? Right now a fresh iles instance is broken right after install. I tried to massage my package lock into working but was less successful than @ohuu

This also fixes #242

@ohuu
Copy link

ohuu commented Feb 15, 2024

Hey @ElMassimo I'd really like to contribute to Iles, maybe this would be a good issue to tackle but I'd need some onboarding to the project. Is there any docs which would help me to setup a dev environment so I can start working on it?

@ElMassimo
Copy link
Owner

Hi Oliver! That would be great! 馃槂

I haven't written an onboarding guide to the project itself, but typically all you need is a modern Node version (20, for example), and pnpm to install dependencies for the entire project.

Building packages can be done by running pnpm run build inside each package, or pnpm run dev to keep a daemon running to rebuild the package as you change the source code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants