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

.client module splitting doesn't respect app directory #9743

Open
Ty3uK opened this issue Jul 11, 2024 · 0 comments
Open

.client module splitting doesn't respect app directory #9743

Ty3uK opened this issue Jul 11, 2024 · 0 comments

Comments

@Ty3uK
Copy link

Ty3uK commented Jul 11, 2024

Reproduction

https://stackblitz.com/edit/remix-run-remix-dt9m1n?file=app%2Froutes%2F_index.tsx

According to discussion about server/client module splitting .client and .server files/folders should be banned only if it places inside app directory.

As I can see there is a missing check inside this code that will check is id belongs to remixConfig.appDirectory.

If this is correct I can make PR but I don't know how to write a test for Vite plugin.

System Info

System:
    OS: Linux 6.9 Fedora Linux 40 (Forty)
    CPU: (8) x64 AMD Custom APU 0405
    Memory: 4.75 GB / 14.47 GB
    Container: Yes
    Shell: 5.2.26 - /bin/bash
  Binaries:
    Node: 20.15.0 - /run/user/1000/fnm_multishells/52679_1720698307557/bin/node
    Yarn: 3.8.3 - /run/user/1000/fnm_multishells/52679_1720698307557/bin/yarn
    npm: 10.7.0 - /run/user/1000/fnm_multishells/52679_1720698307557/bin/npm
  npmPackages:
    @remix-run/dev: ^2.10.2 => 2.10.2 
    @remix-run/node: ^2.10.2 => 2.10.2 
    @remix-run/react: ^2.10.2 => 2.10.2 
    @remix-run/serve: ^2.10.2 => 2.10.2 
    vite: ^5.3.3 => 5.3.3

Used Package Manager

yarn

Expected Behavior

Renders "should fetch"

Actual Behavior

Object.getOwnPropertyDescriptor(...) is undefined

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

No branches or pull requests

2 participants