367 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
1
answer
47
views
Adding graphics to a ReasonML project
I've looked at this question -- How do I add an OCaml library reference to a Reason code file? -- which shows how to add an OCaml library to a ReasonML project. But it doesn't seem to be working for ...
0
votes
0
answers
83
views
How do you connect a src module in Melange with it's associated test file that's using Melange-Jest?
I have a Melange project with the following directory structure:
├── src
│ ├── dune
│ ├── App.re
├── __tests__
│ ├── dune
│ ├── App_test.re
The dune files in both the src and __tests__ ...
0
votes
0
answers
102
views
Failure during standard install of Reason on MacOs (updated by author)
I'm following the install procedure at https://reasonml.github.io/docs/en/installation.
(The MacOs CLI tools provided by Xcode have been installed.)
The specified commands to install Reason and run a ...
0
votes
2
answers
195
views
Convert Json array to list of strings
I am reading this tutorial https://www.stackbuilders.com/blog/nonsense-getting-started-with-reason-and-reason-react/. One of the problems I am facing is that api.noopschallenge.com is now dead. I ...
0
votes
1
answer
109
views
OCaml error: "The present constructor Function__webkit_gradient has a conjunctive type"
What this error means and how can i solve it? I am trying to generate types based on the CSS spec at styled-ppx and got stuck at this error that i dont know how to it fix neither what that means ...
2
votes
1
answer
253
views
Does genType library supports generating types from typescript to rescript/reasonml? [closed]
I’m very new to reasonml/rescript community, What I know genType generates TS/flow types from rescript component while working in existing Typescript/flow codebase. Is there any other way around like ...
1
vote
1
answer
185
views
How can I use react-datepicker in the ReScript app
I`m trying to use an external library such as react-datepicker.
My code and usage:
module DatePicker = {
@react.component @module("react-datepicker")
external make: () => React....
0
votes
1
answer
64
views
How to switch the type of an item in my type signature? [closed]
I'm sorry if my vernacular is wrong here. I'm very new to coding.
I have created two records. I want my program to take in these two records. However, in the type signature both of the items are ...
1
vote
1
answer
60
views
Why is inserting this string into a record throwing an error?
I am trying to insert a string into a record type, which is a list of strings. However, the semicolon after the record keeps throwing an error. Also a couple of lines down there's a type error that I ...
4
votes
1
answer
492
views
ReScript, TypeScript: Cannot find module '@rescript/react/src/ReactDOM.gen' or its corresponding type declarations
I am gradually rewriting an application with React to TypeScript into ReScript.
I've already implemented few components in ReScript, but this is the first one, where I use ReactDOM.Style.t as property ...
1
vote
1
answer
192
views
Curry.js error when exporting a rescript function with more than 1 parameter using genType
When exporting a function with more than 1 parameter (2 or more) it throws the following error, which basically says there is an issue with the way we import curry.js. I am attaching an example and ...
1
vote
1
answer
624
views
How do I use modulus operator in Reason React?
When using the % operator in reason react I am left with an error "The value % can't be found". Is there another word for % used in Reason react?
Js.log(20 % 2)
0
votes
1
answer
65
views
Reasonml syntax meaning |
What does this symbol mean in ReasonML |
E.g
type something =
| SomeFunc()
| AnotherFunc()
I couldnt really find an answer on the ReasonML docs
0
votes
1
answer
204
views
How do I add an OCaml library reference to a Reason code file?
Just began with Reason and OCaml today. I've started with the https://github.com/esy-ocaml/hello-reason sample. I want to make a HTTP API call so I've installed ocaml-cohttp with: esy add @opam/cohttp-...
2
votes
3
answers
630
views
How to use a JavaScript Material Design library in ReScript?
I am trying to use the material-ui library in a Rescript/React app. The code below will show a button:
@module("@material-ui/core/Button") external button: string = "default"
@...