1.0.0 • Published 3 years ago

netsuite-api-2-ts v1.0.0

Weekly downloads
7
License
MIT
Repository
github
Last release
3 years ago

NetSuite API 2.0 TypeScript Declaration File

This package provides a TypeScript declaration file for NetSuite API 2.0 scripts. This effectively gives you intelligent code completion for editing NetSuite scripts within the editor of your choice.

Example usage

Usage In VSCode

Add the type declaration file to your folder (either manually or via npm - npm install netsuite-api-2-ts).

Add a tsconfig.json file to your project similar to the following:

{
  "compilerOptions": {
    "allowJs": true,
    "allowSyntheticDefaultImports": true,
    "baseUrl": "./",
    "checkJs": true,
    "module": "ESNext",
    "moduleResolution": "classic",
    "outDir": "lib",
    "paths": {
      "*": [
        "@types/*",
      ]
    },
    "target": "ESNext",
    "typeRoots": [
    ]
  },
  "include": [
    "./**/*"
  ]
}

The above code assumes that the .d.ts file is located in the folder ./@types.

Using this in combination with the NetSuite Upload extension can completely replace the need for NetSuite's SuiteCloud IDE.

Contributing

The declaration file is edited manually. Not every entity in the API has been added to the declaration file yet. If there is something you would like to add, use NetSuite's API Reference to figure out the syntax and add it directly to netsuite-api-2.d.ts and create a pull request.

1.0.0

3 years ago

0.0.1-security

3 years ago