Giter Site home page Giter Site logo

Comments (9)

enuchi avatar enuchi commented on July 29, 2024 1

Hi @ieow @jsbrain I updated this package addressing the issues you mentioned and republished as [email protected].

PR with changes here: enuchi/gas-types-detailed#2

Sorry for taking a while on this one. Please reopen if you find other issues with the package.

from react-google-apps-script.

ieow avatar ieow commented on July 29, 2024

same issue for the method getSheetValues. It should be returning any[][] instead of object[][]

https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/google-apps-script/google-apps-script.spreadsheet.d.ts
line 1863 and 1697:
getSheetValues(startRow: Integer, startColumn: Integer, numRows: Integer, numColumns: Integer): any[][];

from react-google-apps-script.

enuchi avatar enuchi commented on July 29, 2024

Hm thanks for pointing out. I made a fork that has more detailed docs: https://www.npmjs.com/package/gas-types-detailed

But it may have mistakes, as you pointed out. For now you can remove this package and install @types/google-apps-script, and you may be able to get more up-to-date type definitions.

from react-google-apps-script.

ieow avatar ieow commented on July 29, 2024

I forgot to mention that I was planning to file the issue at github.com/enuchi/gas-types-detailed
but I got 404. So I can only file it here.
Sorry for the lack of info

from react-google-apps-script.

ieow avatar ieow commented on July 29, 2024

additional finding.

in google-apps-script.base.d.ts
line 14

interface Blob need to extend BlobSource

    interface Blob extends BlobSource {

from react-google-apps-script.

enuchi avatar enuchi commented on July 29, 2024

Sorry, I had it as private. I just made it public -- can you add issues and/or feel free to open a PR there:
https://github.com/enuchi/gas-types-detailed

See this thread and fork on how to generate the docs in case that needs to get updated:
PopGoesTheWza/dts-google-apps-script#2
https://github.com/enuchi/dts-google-apps-script/

from react-google-apps-script.

jsbrain avatar jsbrain commented on July 29, 2024

There's a DefinitelyTyped types package available. So running npm i -D @types/google-apps-script and changing tsconfig.json to

{
  "compilerOptions": {
    "types": ["@types/google-apps-script"],
    "jsx": "react",
    "esModuleInterop": true
  }
}

works just fine. Ideally this might be changed in the repo altogether?

from react-google-apps-script.

enuchi avatar enuchi commented on July 29, 2024

I created gas-types-detailed to include full descriptions on each class/method from the official Google docs. However it is out of date and probably some of the types are wrong/missing.

DefinitelyTyped's @types/google-apps-script doesn't have descriptions but the types are more likely to be accurate and up to date.

from react-google-apps-script.

jsbrain avatar jsbrain commented on July 29, 2024

Yeah I just realized that even though the name suggests it. My bad but thanks for the heads up!

from react-google-apps-script.

Related Issues (20)

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.