Skip to content

Instantly share code, notes, and snippets.

@kartiknair
Last active March 10, 2020 07:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kartiknair/4eee5d0e933a028a9731f6dae3770b21 to your computer and use it in GitHub Desktop.
Save kartiknair/4eee5d0e933a028a9731f6dae3770b21 to your computer and use it in GitHub Desktop.
const config = require("./config");
const posts = fs
.readdirSync(config.dev.postsdir)
.map(post => post.slice(0, -3));
console.log(posts);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment