Giter Site home page Giter Site logo

crab-ts's Introduction

crab-ts's People

Contributors

trvswgnr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

crab-ts's Issues

Syntax enhancement

Hello,

I only checked Result and Option traits TS implementations and tests so far but it looks really nice !
(I might use these trait implementations for personal TS projects - if it's ok with you :))

Do you know if a minor refactor would be possible, so that we can use :

const x: Option<number> = None;
instead of
const x: Option<number> = None();

Maybe by renaming None type to NoneType type and use a trick to avoid a function call when storing None into an Option variable
(but idk, maybe there is a cleaner way of implementing this) ?

Sorry if i bore you with syntax details but if possible, i would like to stick with rust syntax.

Note 1 : i don't know which is the best implementation for Result/Option : Unions types + function implementation or Class implementation, but so far what you wrote with Classes looks coherent

Note 2 : i have to play a bit with crab-ts in order to see if there are some possible extensions (handy promise handling/await, etc)

And whatever i say, still great work !
Best regards

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.