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

Running tea with Melange #144

Open
idkjs opened this issue Jun 16, 2021 · 7 comments
Open

Running tea with Melange #144

idkjs opened this issue Jun 16, 2021 · 7 comments

Comments

@idkjs
Copy link

idkjs commented Jun 16, 2021

Hi @OvermindDL1

I tried building something with this and running the program gets you the error main is not a function

Here is a reproduction -> feluxe/bs-tea-starter-kit#3

The error occurs on the example and on Usage.re which is copied from these docs.

Thanks for any guidance.

@OvermindDL1
Copy link
Owner

I'm not really sure I can recommend using this project for new code since bucklescript's changes over the past year have broken a lot of various things, it seems to be going more toward a non-ocaml setup rather than something that transparently handles all setups. I'll accept a PR if you find a fix for this (or if you want to take up overall work then I can give full access), but I'm not sure it's worth trying to "upgrade" to a newer bs-platform version. If you use bs-platform things you might want to stick with the older versions that implement to OCaml more correctly. Otherwise JSOO has some fantastic tea-like API's as well.

@idkjs
Copy link
Author

idkjs commented Jun 28, 2021

@OvermindDL1 I hear it. I might see how far the upgrade goes version by version of bucklescript and try to figure it out. Mostly because there is a lot of value in this project as an example of what is possible. Hate to see it get mothballed. Thanks for the feedback. I will revert if I get anywhere.

@idkjs
Copy link
Author

idkjs commented Jul 3, 2021

@jayesh-bhoot has it working here https://github.com/jayesh-bhoot/spiced-tea. FYI.

@OvermindDL1
Copy link
Owner

OvermindDL1 commented Jul 21, 2021

@idkjs If it's working there then that's still using a main function, what changed in the BS api?

Please feel free to PR any fixes though!

@jyssh
Copy link

jyssh commented Jul 21, 2021

I agree with @OvermindDL1 .

All I did in https://github.com/jayesh-bhoot/spiced-tea was to make bucklescript-tea work with melange, and document that. The API works as-is.

I don’t see why anything should change in this repo, may be except documenting the integration with melange.

@tcoopman
Copy link
Contributor

I can confirm that everything works as-is with melange. I've also created a sample repo that integrates with dream and adds tailwindcss: https://github.com/tcoopman/dream-melange-tea-tailwind

@idkjs idkjs changed the title main is not a function error Running tea with Melange Jul 26, 2021
@OvermindDL1
Copy link
Owner

I'm really curious if someone could figure out what's the different in OP's example then, I wonder if there might be a compat issue then....

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

4 participants