Code Monkey home page Code Monkey logo

create-rescript-app's Issues

Transfer to rescript-lang org

Hi @mahezsh,

We will be removing the built-in templates ("rescript init") from the ReScript compiler in version 11 as they are completely outdated, see rescript-lang/rescript-compiler#5682.

We would like to keep such functionality (creation of new projects from templates) decoupled from the compiler in the future.

I like the simple approach taken in your create-rescript-app project. Would it be possible to transfer it to the rescript-lang organization so that we can continue maintaining it there, and also give the ReScript team access to the create-rescript-app npm package?

Long cmd does not work

Works:

yarn create rescript-app my-app -b

Does not work:

yarn create rescript-app my-app --basic

Why is it still trying to use npm when bootstrapping from Bun?

$ bun create rescript-app

Error: Command failed: npm view rescript versions --json
│  'npm' is not recognized as an internal or external command,
│  operable program or batch file.
│
│
└  Project creation failed.

■  Canceled

This is a command directly from the website...

Basic template: rescript.json contains "module": "esmodule" and "suffix": ".res.js"

When using create-rescript-app 1.7.1 (and picking the basic template + ReScript 11.1.1 + ReScript 1.4.0), the rescript.json file created for a new project looks like this:

{
  // …
  "package-specs": {
    "module": "esmodule",
    "in-source": true
  },
  "suffix": ".res.js",
  // …
}

Thus, building the project and running node src/Demo.res.js will lead to Node.js complaining about a syntax error (“Unexpected token 'export'”).

Only 2 of 5 templates working

Of the 5 templates

basicRepo = "https://github.com/rescript-lang/rescript-project-template.git"
defaultRepo = "https://github.com/mahezsh/rescript-template-default.git"
nextJsRepo = "https://github.com/ryyppy/rescript-nextjs-template.git"
graphqlRepo = "https://github.com/mahezsh/rescript-template-graphql.git"
sbRepo = "https://github.com/mahezsh/rescript-template-storybook.git"

only basic and nextJs are currently working.

@mahezsh What happened to the three templates under https://github.com/mahezsh?

When adding to existing project with TS, configure gentype

This could be a neat thing - configure gentype automatically whenever adding to an existing project with TS already installed.

We could:

  • Detect the config needed for "module" and "moduleResolution" in gentype via tsconfig.json
  • Warn of allowJs is not true in tsconfig.json and explain why it's needed

Going for a "1 command to get setup" approach.

cc @cometkim

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.