Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

the type of schema applied to the document is not supported package.json

Can anyone explain what this warning in my package.json file is? I have searched a little bit but I cannot seem to understand if this is just compatibility/strange behavior or if there is something going on worse than that.

I have taken a screenshot of the warning message below. I apologize if this has been answered elsewhere and I overlooked it.

Attached is my package.json in full:

{     "$schema": "./node_modules/@angular/cli/lib/config/schema.json",     "version": 1,     "projects": {         "project": {             "architect": {                 "lint": {                     "builder": "@angular-devkit/build-angular:tslint",                     "options": {                         "exclude": [ "**/node_modules/**" ],                         "tsConfig": [ "tsconfig.json" ]                     }                 },                 "build": {                     "builder": "@angular-devkit/build-angular:browser",                     "options": {                         "aot": true,                         "assets": [ "src/favicon.ico" ],                         "index": "src/index.html",                         "main": "src/main.ts",                         "outputPath": "dist",                         "polyfills": "src/polyfills.ts",                         "scripts": [                             "node_modules/uikit/dist/js/uikit.min.js",                             "node_modules/uikit/dist/js/uikit-icons.min.js"                         ],                 "styles": [                 "node_modules/uikit/dist/css/uikit.min.css",                 "src/styles.scss",                 "node_modules/bootstrap/dist/css/bootstrap.min.css"                 ],                         "tsConfig": "tsconfig.json"                     },                     "configurations": {                         "development": {                             "baseHref": "/aspnetcoreangular/",                             "buildOptimizer": true,                             "extractCss": true,                             "extractLicenses": true,                             "namedChunks": false,                             "optimization": true,                             "outputHashing": "all",                             "sourceMap": false,                             "vendorChunk": false                         },                         "production": {                             "fileReplacements": [                                 {                                     "replace": "src/environments/environment.ts",                                     "with": "src/environments/environment.production.ts"                                 }                             ],                             "baseHref": "/aspnetcoreangular/",                             "buildOptimizer": true,                             "extractCss": true,                             "extractLicenses": true,                             "namedChunks": false,                             "optimization": true,                             "outputHashing": "all",                             "sourceMap": false,                             "vendorChunk": false                         },                         "staging": {                             "fileReplacements": [                                 {                                     "replace": "src/environments/environment.ts",                                     "with": "src/environments/environment.staging.ts"                                 }                             ],                             "baseHref": "/aspnetcoreangular/",                             "buildOptimizer": true,                             "extractCss": true,                             "extractLicenses": true,                             "namedChunks": false,                             "optimization": true,                             "outputHashing": "all",                             "sourceMap": false,                             "vendorChunk": false                         }                     }                 },                 "serve": {                     "builder": "@angular-devkit/build-angular:dev-server",                     "options": { "browserTarget": "project:build" }                 }             },             "cli": {                 "warnings": {                     "typescriptMismatch": false,                     "versionMismatch": false                 }             },             "prefix": "app",             "projectType": "application",             "root": "",             "sourceRoot": "src"         }     } } 
like image 742
Justin Le Avatar asked Jul 23 '18 16:07

Justin Le


1 Answers

https://developercommunity.visualstudio.com/t/support-json-schema-draft-06-draft-07/796216

VS still doesn't support draft 7 for json-schemes and is stuck at draft 4-5. Hence the warning.

It's a false positive.

EDIT

Mike (see below) suggests a work around. Be sure to check it out and give Mike an upvote if it works (so that he'll be the first answer listed).

like image 156
qqtf Avatar answered Nov 01 '22 11:11

qqtf