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

[wip] fix: d3 upgrade breaking change #125

Closed
wants to merge 3 commits into from

Conversation

yamashush
Copy link
Contributor

@yamashush yamashush commented Jan 8, 2023

d3 became pure ES modules form 7.0.
ref: https://github.com/d3/d3/blob/main/CHANGES.md#changes-in-d3-70

I changed TypeScript output format from CommonJS to EMS.
I've seen that it works in my local environment.

ref: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
ref: https://www.typescriptlang.org/docs/handbook/esm-node.html

Sorry if you prefer CommonJS 🙏

Related: #124 #109

@yamashush
Copy link
Contributor Author

@vn7n24fzkq When you are free, can you give me a review? 😄

@vn7n24fzkq
Copy link
Owner

I am just checking the preview page.
Seems something is broken.
https://github-profile-summary-cards-fu8yrr2k0.vercel.app/demo.html

2023-01-10T15:08:32.655Z	undefined	ERROR	Error: Cannot find module '/var/task/src/const/theme' imported from /var/task/api/theme.js
    at new NodeError (node:internal/errors:372:5)
    at finalizeResolution (node:internal/modules/esm/resolve:437:11)
    at moduleResolve (node:internal/modules/esm/resolve:1009:10)
    at defaultResolve (node:internal/modules/esm/resolve:1218:11)
    at ESMLoader.resolve (node:internal/modules/esm/loader:580:30)
    at ESMLoader.getModuleJob (node:internal/modules/esm/loader:294:18)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:80:40)
    at link (node:internal/modules/esm/module_job:78:36) {
  code: 'ERR_MODULE_NOT_FOUND'
}
RequestId: d9e12edf-7047-46f4-9220-d7f5350811a1 Error: Runtime exited with error: exit status 1
Runtime.ExitError

Maybe we need to modify all of CJS import usage to EMS?
If this is tricky we can just merge #124 and close this one temporarily.

@yamashush
Copy link
Contributor Author

yamashush commented Jan 10, 2023

Thanks for shareing 😄
Can you tell me how to start the demo site in a local environment?

I'll continue to try this problem, but we might to merge #124 to get the repository in the right state :)

@vn7n24fzkq
Copy link
Owner

Sure, we can merge #124 first.

I usually use Vercel dev to host the services locally.
You can see this doc. https://vercel.com/docs/cli/dev

I will make a development document soon.

@yamashush
Copy link
Contributor Author

Thank you 😄

@yamashush yamashush changed the title fix: d3 upgrade breaking change [wip] fix: d3 upgrade breaking change Jan 11, 2023
@yamashush
Copy link
Contributor Author

yamashush commented Mar 28, 2023

Sorry 🙏 🙏 🙏
Now I don't have time to do this PR, so I'll close.

@yamashush yamashush closed this Mar 28, 2023
@vn7n24fzkq
Copy link
Owner

No need to apologize, I completely understand that sometimes life can get busy and priorities can shift. It's important to manage your time and focus on what matters most to you. If you ever have the time in the future and still wish to do the PR, you can always revisit it at a later time.

Take care and don't hesitate to reach out if you need any further assistance!

And thanks for your contributions again!!

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

Successfully merging this pull request may close these issues.

None yet

2 participants