Closed
Description
From akamud/vscode-theme-onedark#87
Sample code
Extract from https://github.com/facebook/react/blob/master/packages/react-reconciler/src/ReactFiberClassComponent.js#L65
function(callback: mixed, callerName: string) {
if (callback === null || typeof callback === 'function') {
return;
}
const key = `${callerName}_${(callback: any)}`;
if (!didWarnOnInvalidCallback[key]) {
warning(
false,
'%s(...): Expected the last optional `callback` argument to be a ' +
'function. Instead received: %s.',
callerName,
callback,
);
didWarnOnInvalidCallback[key] = true;
}
};
Filename and Language selected
Using .js
extension with JavaScript
file type selected
Screenshot
Versions used
- VSCode version: 1.20.1
- OS Version: macOS 10.13.3