Giter Site home page Giter Site logo

no-bs-ts's People

Contributors

jherr avatar santhoshvai avatar vibhanshu-olx avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

no-bs-ts's Issues

Issues with Property 'children'

I am facing some issue with regards to the props type for children.
Looked up in StackOverflow but I am still not sure how to resolve it.

image
image

Issues with conditionals.ts

I have installed node-fetch dependency. However, the conditionals.ts has an error

Argument of type 'unknown' is not assignable to parameter of type 'PokemonResults'.ts(2345)

Screenshot 2022-01-19 at 17 13 04

The data.json response from the fetch function returns Promise<unknown> type

Fix is to cast data to `Promise

fetch(url)
      .then((data) => data.json() as Promise<PokemonResults>)
      .then((data) => cb(data));

There is also error with fetch.

ts conditionals.ts
Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/node_modules/node-fetch/src/index.js from /Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/conditionals.ts not supported.
Instead change the require of index.js in /Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/conditionals.ts to a dynamic import() which is available in all CommonJS modules.
    at Object.<anonymous> (/Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/conditionals.ts:15:38)
    at Module.m._compile (/Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/node_modules/ts-node/dist/index.js:735:29)
    at Object.require.extensions.<computed> [as .ts] (/Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/node_modules/ts-node/dist/index.js:737:16)
    at main (/Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/node_modules/ts-node/dist/bin.js:238:16)
    at Object.<anonymous> (/Users/tonis/workspace/web/ti-no-bs-ts/ts-basics/node_modules/ts-node/dist/bin.js:351:5) {
  code: 'ERR_REQUIRE_ESM'
}

The solution is to downgrade fetch to v2. link. yarn add node-fetch adds v3 automatically

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.