This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const dedupe = (string) => { | |
const parsed = string.split('') | |
let deduplicate = []; | |
parsed.map(function(value) { | |
if (!deduplicate.includes(value)) { | |
deduplicate.push(value); | |
} | |
}) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Load the AWS SDK, fs and path modules for Node.js | |
import AWS from "aws-sdk"; | |
import fs from "fs"; | |
import path from "path"; | |
// Set the region | |
AWS.config.update({region: "us-west-1"}) | |
// Create S3 service object | |
const s3 = new AWS.S3({apiVersion: "2006-03-01"}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require("express"); | |
const bodyParser = require("body-parser") | |
const ejs = require("ejs"); | |
const app = express(); | |
app.set("view engine", "ejs"); | |
app.use(bodyParser.urlencoded({extended: true})); | |
app.get("/", function(req, res) { |