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

fresh-server-event-handlers should now allow colocated (_islands) directory #1190

Closed
junichi-chiba opened this issue Aug 21, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@junichi-chiba
Copy link

junichi-chiba commented Aug 21, 2023

Lint Name

fresh-server-event-handlers

Code Snippet

Fresh 1.4, located at /routes/mypage/(_islands)/MyIsland.tsx

                  <input
                    type="checkbox"
                    checked={!myvalue}
                    onClick={() => {
                      myaction();
                    }}
                  />

Expected Result

No lint errors

Actual Result

Following lint message is displayed:

Server components cannot install client side event handlers.
hint: Remove this property or turn the enclosing component into an island

Additional Info

Fresh 1.4 now allows placing any islands component under routes, in (_islands) sub-directory.
See https://deno.com/blog/fresh-1.4

Version

deno 1.36.1 (release, aarch64-apple-darwin)
v8 11.6.189.12
typescript 5.1.6
Fresh 1.4.2

@junichi-chiba junichi-chiba added the bug Something isn't working label Aug 21, 2023
@not-ivy
Copy link

not-ivy commented Sep 15, 2023

this should be fixed in #1195 however I dont think it is released yet

@lucacasonato
Copy link
Member

This is released now.

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

3 participants