Generated TypeScript definition files for Slate
see ./packages
for the type definition files.
Run the generation script
sh ./scripts/generate.sh
Generated type definition files for the slate editor
see ./packages
for the type definition files.
Run the generation script
sh ./scripts/generate.sh
I'm not sure if there was a major API change in slate recently but it appears these type definitions don't have declarations for the Value
which is one of the core objects. The repo says last update was 2 months ago so I thought perhaps it's just out of date.
Example:
import { Value } from 'slate'
Module ''slate'' has no exported member 'Value'.
And from looking at the .d.ts file I don't see it either although Document, Range, etc are there.
It seems like this was created as unofficial support as I found it from here:
ianstormtaylor/slate#560
But if it's an easy thing to re-run a script and get new types it might be worth it.
Hi there,
first of all thank you very much for your project and all the work :)
I've cloned the project and run: npm install
and afterward npm run build
. I will get the following errors (there are more for each project):
> [email protected] build /Users/jan/Projects/slate-dts
> sh ./scripts/generate.sh
cloning latest version of slate...
generating typings for slate-auto-replace...
cp: ./.tmp/slate-auto-replace/dist-dts/: No such file or directory
./scripts/generate.sh: line 58: ./packages/slate-auto-replace/package.json: No such file or directory
assert.js:42
throw new errors.AssertionError({
^
AssertionError [ERR_ASSERTION]: main does not exist: /Users/jan/Projects/slate-dts/packages/slate-auto-replace/index.d.ts
at Object.bundle (/Users/jan/Projects/slate-dts/node_modules/dts-bundle/lib/index.js:79:9)
at Object.<anonymous> (/Users/jan/Projects/slate-dts/scripts/dts-bundle.js:4:5)
at Module._compile (module.js:635:30)
at Object.Module._extensions..js (module.js:646:10)
at Module.load (module.js:554:32)
at tryModuleLoad (module.js:497:12)
at Function.Module._load (module.js:489:3)
at Function.Module.runMain (module.js:676:10)
at startup (bootstrap_node.js:187:16)
at bootstrap_node.js:608:3
fs.js:646
return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
^
Error: ENOENT: no such file or directory, open './packages/slate-auto-replace/slate-auto-replace.d.ts'
at Object.fs.openSync (fs.js:646:18)
at Object.fs.readFileSync (fs.js:551:33)
at Object.<anonymous> (/Users/jan/Projects/slate-dts/scripts/definition-modifications.js:6:15)
at Module._compile (module.js:635:30)
at Object.Module._extensions..js (module.js:646:10)
at Module.load (module.js:554:32)
at tryModuleLoad (module.js:497:12)
at Function.Module._load (module.js:489:3)
at Function.Module.runMain (module.js:676:10)
at startup (bootstrap_node.js:187:16)
...done!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.