gdtf-types
v1.0.0
Published
Types for the GDTF file format
Downloads
3
Readme
GDTF TS Schema
How to use
import type { document as GDTFDocument, Model } from 'gdtf-types';
How to build
- Download
gdtf.xsd
from here - Run
npx http-server
in the directory wheregdtf.xsd
is located - Edit that file and add the following attributes to the
xs:schema
tag:targetNamespace="urn:gdtf" elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.0.0"
- Run
npx cxsd http://127.0.0.1:8082/gdtf.xsd
- The generated
gdtf.d.ts
file will be located in thexmlns
folder. You will also need thexml-primitives.d.ts
file from the same folder.
[!IMPORTANT]
Before rebuilding, delete thecache
and thexmlns
folders.