Prisma Highlighter Pro
By Sanjeet Kumar
Version 2.1.0
Prisma Highlighter Pro A CodeMirror 6 Prisma toolkit for Acode: 17 themes, real schema diagnostics, context-aware autocomplete, block badges, folding and workflow commands. Version License Features - Native CodeMirror 6 Prisma language support for every .prisma file (including multi-file schemas) - Highlighting that tells apart block names, field names, scalar types, references to models and enums, enum values, config keys, attributes, @db. native types, argument labels, referential actions and env("...") names. A field named type or view is a field, not a keyword - Diagnostics with messages : problems are underlined, hover or tap shows what is wrong - Context-aware autocomplete : block snippets at the top level, types after a field name, @ attributes, @@ block attributes, native types after @db. , referential actions after onDelete: , field names inside fields: [...] and @@index([...]) , the related model's fields inside references: [...] , enum values and functions inside @default(...) , config keys and providers in datasource / generator blocks - Block badges that summarise each block ( 5 fields · 1 relation , 2 values , the provider) - Folding for every block, and automatic indentation - 17 themes Usage The plugin activates automatically for files ending in .prisma . To force Prisma mode on another file, enable Always highlight as Prisma in the settings. Diagnostics | Severity | Problem | | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Error | Unclosed, duplicate or malformed blocks; unexpected braces; more than one datasource; a datasource or generator without provider | | Error | Duplicate fields or enum values; a field without a type; unterminated strings | | Error | @relation with fields but no references (or the reverse), different numbers of fields and references, unknown fields, an invalid onDelete / onUpdate action | | Error | Unknown fields in @@id , @@unique and @@index ; an @default value that is not a value of the field's enum | | Warning | Unknown types (they may be declared in another schema file), unknown attributes, a model without @id , @@id or @unique , an empty enum | A missing datasource or generator is not reported as a problem, because multi-file schemas keep them in a different file; Show Prisma…