Quantcast
Channel: How to wrap an interface in an object while exporting it in TypeScript? - Stack Overflow
Browsing latest articles
Browse All 2 View Live

Answer by Tomáš Wróbel for How to wrap an interface in an object while...

Objects (every value in JavaScript / TypeScript) can contain only values as properties (methods, constants, properties) which interfaces are not. But don't worry, there's the way! Its name is...

View Article


How to wrap an interface in an object while exporting it in TypeScript?

I have a file called x.ts, here is what it holds:interface x { x: string;}interface y{ x: string;}interface z { x: string;}interface i{ x: string;}I want to export the interfaces like this:export = {...

View Article

Browsing latest articles
Browse All 2 View Live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>