Skip to content

WebReflection/is-es-class

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

is-es-class

Coverage Status build status

Social Media Photo by Markus Winkler on Unsplash

The only reasonable way to understand if a class has been defined, or transpiled, as such.

Explained in this StackOverflow answer.

// const isESClass = require('is-es-class');
import isESClass from 'is-es-class';

isESClass(class {});        // ✅
isESClass(function () {});  // ❌
isESClass(() => {});        // ❌
isESClass({m(){}}.m);       // ❌

About

The only reasonable way to understand if a class has been defined, or transpiled, as such.

Resources

License

Stars

Watchers

Forks

Packages

No packages published