Skip to content

Instantly share code, notes, and snippets.

View noampc's full-sized avatar

Noam Goldface noampc

  • Mamram, IDF
  • Israel, Holon
View GitHub Profile
body {
font: 14px "Century Gothic", Futura, sans-serif;
margin: 20px;
}
ol, ul {
padding-left: 30px;
}
.board-row:after {
@noampc
noampc / server.js
Created December 29, 2017 18:27
Render entire EJS views directory with Express.js
import express from 'express';
import fs from 'fs';
const server = express();
server.set('view engine', 'ejs');
function filesToRender(dir){
function fileSubstring(file, dir){
return file.substring(0, file.length - 4).replace(dir,'')