-
Notifications
You must be signed in to change notification settings - Fork 435
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
Is Typescript totally necessary? #96
Comments
@deltaskelta: Can you please explain the issues you were seeing? Apologies for the long delay in responding to your issue. |
I have since given up and gone with pure typescript, but I just fired up an example with for example...
which is quite obviously coming from the lines...
So I am unsure if the issue is coming form the way I am compiling the files, which is just as prescribed from the |
Hey @deltaskelta, would you be able to provide a minimal set of steps to reproduce the issue? Thanks |
Yes I will try, it might be a few days until I can get around to it. |
I made a repo that simply recreates the issue... If you follow the simple instructions in the README and start the react dev server, you can see the errors. the |
@deltaskelta Thanks for the repo. Looking into it! There's also a mention of this issue on |
When I packed the react project with webpack it resolves all the imports and the result is a working bundle.js. Not, sure but I believe the problem has something to do with the server provided by the create-react-app and with its way of resolving imports and requires. Still the webpack solution isn't ideal for the developing process itself, so a better solution would be great! |
I came to a similar finding yesterday, it looks to be related to create-react-app rather. A non create-react-app setup works fine for me. Will dig deeper into what's triggering this in create-react-app. |
What do you mean by "packed"? do you mean you ejected the webpack config from the stock I suspected it might be a webpack issue but I tried some different loaders and didn't have much luck. |
I created a webpack config myself and after webpacking it I used the output bundle.js and an index.html with a different server than the create-react-app one. |
ok, could you post the webpack config here? or a gist? |
I can confirm that there are no issues when using webpack outside of create-react-app. Here's a grpc-web-js-examle repo with a working pure JS usage of grpc-web. Will continue to investigate why |
ok thanks I'll look into it too |
I figured out what was causing it in It is only failing to compile because the default react-scripts forces eslint errors to fail to compile. It is part of
Thanks for your time in helping troubleshoot this issue |
It seems this problem in create-react-app is wider than the protobuf issue. |
@jonathan-se your link text shows the right place, but it actually links right to this thread |
Here is my bash script. First loop generates .js and .ts files. TS out is not necessary here, but it helps a lot in IDE.
|
That's so interesting. above two solution work for me. Is it possible to add alla generated js files to a specific folder and setting react lint ignore? |
Needed because of: improbable-eng/grpc-web#96 (comment)
I am wondering if this can be made to use with plain ES5 javascript without the typescript bits. I tried for a while to integrate it in a normal ReactJS workflow but I could not do it without TS
The text was updated successfully, but these errors were encountered: