Answers for "import as type ts"

2

import json typescript

// add this in your tsconfig.json file:
{
  "compilerOptions": {
    "resolveJsonModule": true
  }
}
Posted by: Guest on October-01-2021
1

import js file in typescript

// Add to tsconfig.json:
{
  "compilerOptions": {
      ...
      "allowJs": true
      ...
  }
}
  
import MyModule from './../pages/MyModule';
Posted by: Guest on April-27-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language