Skip to content

Commit

Permalink
adding favicon
Browse files Browse the repository at this point in the history
  • Loading branch information
HassanMasoud committed Jul 25, 2019
1 parent a1df5bb commit ebac142
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"ejs": "^2.6.2",
"express": "^4.17.1",
"express-ejs-layouts": "^2.5.0",
"express-favicon": "^2.0.1",
"method-override": "^3.0.0",
"mongoose": "^5.6.4"
},
Expand Down
Binary file added public/favicon.ico
Binary file not shown.
2 changes: 2 additions & 0 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const app = express();
const expressLayouts = require("express-ejs-layouts");
const mongoose = require("mongoose");
const methodOverride = require("method-override");
const favicon = require("express-favicon");

mongoose.connect(process.env.DATABASE_URL, { useNewUrlParser: true });
const db = mongoose.connection;
Expand All @@ -24,6 +25,7 @@ app.use(methodOverride("_method"));
app.use(expressLayouts);
app.use(express.static("public"));
app.use(express.urlencoded({ limit: "10mb", extended: false }));
app.use(favicon(__dirname + "/public/favicon.ico"));

app.use("/", indexRoute);
app.use("/authors", authorRoute);
Expand Down

0 comments on commit ebac142

Please sign in to comment.