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

GenType does not handle JSON types in Core properly #7157

Open
jmagaram opened this issue Nov 11, 2024 · 1 comment
Open

GenType does not handle JSON types in Core properly #7157

jmagaram opened this issue Nov 11, 2024 · 1 comment

Comments

@jmagaram
Copy link
Contributor

Sample project:

https://github.com/jmagaram/functors

Look at file Simple.res with the code:

@genType
let hello = JSON.Encode.string("hello")

The TypeScript is...

import * as SimpleJS from './Simple.res.mjs';
import type {t as Core__JSON_t} from '@rescript/core/src/Core__JSON.gen';
export const hello: Core__JSON_t = SimpleJS.hello as any;

And the error on the second line is...

Cannot find module '@rescript/core/src/Core__JSON.gen' or its corresponding type declarations.

@jmagaram
Copy link
Contributor Author

Might be related to #6563

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

1 participant