Skip to content

shaunluttin/typescript-library-unknown-older-targets

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

git clone git@github.com:shaunluttin/typescript-library-unknown-older-targets.git

cd library-ts3.5
npm install
npm run build

cd ../consumer-ts2.0
npm install
npm run build // Good! There is no error because unknown is an alias for any.

cd ../consumer-ts3.1
npm install
npm run build // Good! There is an error because unknown is not assignable to number.

About

Demo of how to support `unknown` in older versions of TypeScript.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published