[Home] > Snippets  > Languages  > JavaScript  > Fn  >  Create an empty function

Create an empty function

JavaScript

const noop = () => {}

// Or
const noop = Function()
// calling Function() might be detected as using eval by some security tools