diff --git a/.browserslistrc b/.browserslistrc
new file mode 100644
index 0000000..42edce4
--- /dev/null
+++ b/.browserslistrc
@@ -0,0 +1,4 @@
+>1%
+last 4 versions
+Firefox ESR
+not ie < 9
\ No newline at end of file
diff --git a/README.md b/README.md
index f9800d9..12e1d88 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,8 @@
# Readlebee
-[![Read our Contribution Guidelines](https://badges.frapsoft.com/os/v1/open-source.svg?v=102)](./CONTRIBUTING.md) [![Issues](https://img.shields.io/github/issues/Alamantus/Readlebee.svg)](https://gitlab.com/Alamantus/Readlebee/issues) [![Join the chat at https://gitter.im/Readlebee/community](https://badges.gitter.im/Readlebee/general.svg)](https://gitter.im/Readlebee/community)
+[![Read our Contribution Guidelines](https://badges.frapsoft.com/os/v1/open-source.svg?v=102)](./CONTRIBUTING.md) [![Join the chat at https://gitter.im/Readlebee/community](https://badges.gitter.im/Readlebee/general.svg)](https://gitter.im/Readlebee/community) [![Dependencies Status](https://david-dm.org/Alamantus/Readlebee.svg)](https://david-dm.org/Alamantus/Readlebee) [![DevDependencies Status](https://david-dm.org/Alamantus/Readlebee/dev-status.svg)](https://david-dm.org/Alamantus/Readlebee?type=dev)
-An attempt at a viable alternative to Goodreads (currently lacking a name—ideas welcome!)
+An attempt at a viable alternative to Goodreads
## Important Links
diff --git a/package.json b/package.json
index 0f66646..02ececd 100644
--- a/package.json
+++ b/package.json
@@ -20,8 +20,7 @@
"autoprefixer": "^9.6.1",
"choo-devtools": "^3.0.1",
"concurrently": "^4.1.2",
- "cross-env": "^5.2.1",
- "cssnano": "^4.1.10",
+ "cross-env": "^6.0.0",
"faker": "^4.1.0",
"parcel-bundler": "^1.12.3",
"parcel-plugin-goodie-bag": "^2.0.0",
@@ -40,8 +39,6 @@
"fastify-jwt": "^1.0.0",
"fastify-postgres": "^2.0.0",
"fastify-static": "^2.5.0",
- "handlebars": "^4.2.0",
- "html-minifier": "^4.0.0",
"make-promises-safe": "^5.0.0",
"node-fetch": "^2.6.0",
"pg": "^7.12.1",
diff --git a/server/views/home.hbs b/server/views/home.hbs
deleted file mode 100644
index 468eeea..0000000
--- a/server/views/home.hbs
+++ /dev/null
@@ -1,20 +0,0 @@
-{{#> layout }}
-
-{{#*inline "page-content-block" }}
-
- {{#if message }}
-
- {{ message }}
-
- {{/if}}
-
- {{#if loggedIn }}
- {{> home-logged-in }}
- {{ else }}
- {{> home-logged-out }}
- {{/if}}
-
-
-{{/inline}}
-
-{{/layout}}
\ No newline at end of file
diff --git a/server/views/layout.hbs b/server/views/layout.hbs
deleted file mode 100644
index 98c52e3..0000000
--- a/server/views/layout.hbs
+++ /dev/null
@@ -1,42 +0,0 @@
-
-
-
-
-
-
-
- {{ pageTitle }}
-
-
-
-
-
-
-
-
-
-
-
- {{!-- This is controlled by the resources router. --}}
-
-
-
-{{#> header-block }}
- {{> header }}
-{{/header-block}}
-
-
-{{#> page-content-block }}
- {{!-- Wrap the actual page content in {{#*inline "page-content-block"}} to insert it here --}}
-{{/page-content-block}}
-
-
-{{#> footer-block }}
- {{> footer }}
-{{/footer-block}}
-
-{{#> scripts-block }}
-{{/scripts-block}}
-
-
-
\ No newline at end of file
diff --git a/server/views/login.hbs b/server/views/login.hbs
deleted file mode 100644
index e863b81..0000000
--- a/server/views/login.hbs
+++ /dev/null
@@ -1,23 +0,0 @@
-{{#> layout }}
-
-{{#*inline "page-content-block" }}
-
-{{/inline}}
-
-{{/layout}}
\ No newline at end of file
diff --git a/server/views/partials/footer.hbs b/server/views/partials/footer.hbs
deleted file mode 100644
index bdd7064..0000000
--- a/server/views/partials/footer.hbs
+++ /dev/null
@@ -1,8 +0,0 @@
-
diff --git a/server/views/partials/header.hbs b/server/views/partials/header.hbs
deleted file mode 100644
index 559d12d..0000000
--- a/server/views/partials/header.hbs
+++ /dev/null
@@ -1,23 +0,0 @@
-
diff --git a/server/views/partials/home-logged-in.hbs b/server/views/partials/home-logged-in.hbs
deleted file mode 100644
index e82c1a8..0000000
--- a/server/views/partials/home-logged-in.hbs
+++ /dev/null
@@ -1,16 +0,0 @@
-
- You are logged in!
-
- {{#each statuses }}
-
-
- A status about {{title}}
-
-
-
- {{/each}}
-
-
\ No newline at end of file
diff --git a/server/views/partials/home-logged-out.hbs b/server/views/partials/home-logged-out.hbs
deleted file mode 100644
index 1ce0918..0000000
--- a/server/views/partials/home-logged-out.hbs
+++ /dev/null
@@ -1,18 +0,0 @@
-An attempt at a viable alternative to Goodreads
-
-
-
-
-
\ No newline at end of file
diff --git a/server/views/search.hbs b/server/views/search.hbs
deleted file mode 100644
index beac538..0000000
--- a/server/views/search.hbs
+++ /dev/null
@@ -1,37 +0,0 @@
-{{#> layout }}
-
-{{#*inline "page-content-block"}}
-
- An attempt at a viable alternative to Goodreads
-
-
-
- {{#each results }}
-
-
-
- {{#each covers }}
-
- {{/each}}
-
- {{title}}
-
- {{#each authors }}
- {{this}}
- {{/each}}
-
-
-
- {{/each}}
-
-
-
-{{/inline}}
-
-{{#*inline "footer-block"}}
-{{#if arbitraryContent}}
- {{arbitraryContent}}
-{{/if}}
-{{/inline}}
-
-{{/layout}}
\ No newline at end of file
diff --git a/server/views/viewSetup.js b/server/views/viewSetup.js
deleted file mode 100644
index b6f6717..0000000
--- a/server/views/viewSetup.js
+++ /dev/null
@@ -1,31 +0,0 @@
-const fs = require('fs');
-const path = require('path');
-
-const partialFiles = fs.readdirSync(path.resolve(__dirname, 'partials')); // This is resolved from *this file's* dirname
-const partials = {
- layout: 'layout.hbs',
-};
-partialFiles.forEach(file => {
- if (file.includes('.hbs')) {
- const name = file.replace('.hbs', '');
- partials[name] = `partials/${file}`;
- }
-});
-
-module.exports = { // Adds the `view()` function to fastify's `reply` objects
- engine: {
- handlebars: require('handlebars'), // Use handlebar as the render engine for `reply.view()`
- },
- templates: 'views', // Search for all files referenced in `reply.view()` within the `views/` folder
- options: {
- useHtmlMinifier: require('html-minifier'), // Add a minifier to the rendered HTML output
- htmlMinifierOptions: {
- removeComments: true,
- removeCommentsFromCDATA: true,
- collapseWhitespace: true,
- collapseBooleanAttributes: true,
- removeEmptyAttributes: true
- },
- partials, // Specifies the Handlebars Partials so `point-of-view` knows where they are within the `views` folder and what they're called when referenced in a `.hbs` file
- },
-}
\ No newline at end of file
diff --git a/yarn.lock b/yarn.lock
index 6d2d40a..29756fa 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -1562,13 +1562,6 @@ class-utils@^0.3.5:
isobject "^3.0.0"
static-extend "^0.1.1"
-clean-css@^4.2.1:
- version "4.2.1"
- resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-4.2.1.tgz#2d411ef76b8569b6d0c84068dabe85b0aa5e5c17"
- integrity sha512-4ZxI6dy4lrY6FHzfiy1aEOXgu4LIsW2MhwG0VBKdcoGoH/XLFgaHSdLTGr4O8Be6A8r3MOphEiI8Gc1n0ecf3g==
- dependencies:
- source-map "~0.6.0"
-
cli-cursor@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5"
@@ -1672,7 +1665,7 @@ command-exists@^1.2.6:
resolved "https://registry.yarnpkg.com/command-exists/-/command-exists-1.2.8.tgz#715acefdd1223b9c9b37110a149c6392c2852291"
integrity sha512-PM54PkseWbiiD/mMsbvW351/u+dafwTJ0ye2qB60G1aGQP9j3xK2gmMDc+R34L3nDtx4qMCitXT75mkbkGJDLw==
-commander@^2.11.0, commander@^2.19.0, commander@^2.20.0, commander@~2.20.0:
+commander@^2.11.0, commander@^2.19.0, commander@^2.20.0:
version "2.20.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422"
integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==
@@ -1814,14 +1807,14 @@ create-hmac@^1.1.0, create-hmac@^1.1.2, create-hmac@^1.1.4:
safe-buffer "^5.0.1"
sha.js "^2.4.8"
-cross-env@^5.2.1:
- version "5.2.1"
- resolved "https://registry.yarnpkg.com/cross-env/-/cross-env-5.2.1.tgz#b2c76c1ca7add66dc874d11798466094f551b34d"
- integrity sha512-1yHhtcfAd1r4nwQgknowuUNfIT9E8dOMMspC36g45dN+iD1blloi7xp8X/xAIDnjHWyt1uQ8PHk2fkNaym7soQ==
+cross-env@^6.0.0:
+ version "6.0.0"
+ resolved "https://registry.yarnpkg.com/cross-env/-/cross-env-6.0.0.tgz#3c8e71440ea20aa6faaf5aec541235efc565dac6"
+ integrity sha512-G/B6gtkjgthT8AP/xN1wdj5Xe18fVyk58JepK8GxpUbqcz3hyWxegocMbvnZK+KoTslwd0ACZ3woi/DVUdVjyQ==
dependencies:
- cross-spawn "^6.0.5"
+ cross-spawn "^7.0.0"
-cross-spawn@^6.0.0, cross-spawn@^6.0.4, cross-spawn@^6.0.5:
+cross-spawn@^6.0.0, cross-spawn@^6.0.4:
version "6.0.5"
resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4"
integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==
@@ -1832,6 +1825,15 @@ cross-spawn@^6.0.0, cross-spawn@^6.0.4, cross-spawn@^6.0.5:
shebang-command "^1.2.0"
which "^1.2.9"
+cross-spawn@^7.0.0:
+ version "7.0.0"
+ resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.0.tgz#21ef9470443262f33dba80b2705a91db959b2e03"
+ integrity sha512-6U/8SMK2FBNnB21oQ4+6Nsodxanw1gTkntYA2zBdkFYFu3ZDx65P2ONEXGSvob/QS6REjVHQ9zxzdOafwFdstw==
+ dependencies:
+ path-key "^3.1.0"
+ shebang-command "^1.2.0"
+ which "^1.2.9"
+
crypto-browserify@^3.11.0:
version "3.12.0"
resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec"
@@ -3081,17 +3083,6 @@ grapheme-breaker@^0.3.2:
brfs "^1.2.0"
unicode-trie "^0.3.1"
-handlebars@^4.2.0:
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.2.0.tgz#57ce8d2175b9bbb3d8b3cf3e4217b1aec8ddcb2e"
- integrity sha512-Kb4xn5Qh1cxAKvQnzNWZ512DhABzyFNmsaJf3OAkWNa4NkaqWcNI8Tao8Tasi0/F4JD9oyG0YxuFyvyR57d+Gw==
- dependencies:
- neo-async "^2.6.0"
- optimist "^0.6.1"
- source-map "^0.6.1"
- optionalDependencies:
- uglify-js "^3.1.4"
-
har-schema@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92"
@@ -3191,11 +3182,6 @@ hash.js@^1.0.0, hash.js@^1.0.3:
inherits "^2.0.3"
minimalistic-assert "^1.0.1"
-he@^1.2.0:
- version "1.2.0"
- resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f"
- integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==
-
helmet-crossdomain@^0.4.0:
version "0.4.0"
resolved "https://registry.yarnpkg.com/helmet-crossdomain/-/helmet-crossdomain-0.4.0.tgz#5f1fe5a836d0325f1da0a78eaa5fd8429078894e"
@@ -3269,19 +3255,6 @@ html-encoding-sniffer@^1.0.2:
dependencies:
whatwg-encoding "^1.0.1"
-html-minifier@^4.0.0:
- version "4.0.0"
- resolved "https://registry.yarnpkg.com/html-minifier/-/html-minifier-4.0.0.tgz#cca9aad8bce1175e02e17a8c33e46d8988889f56"
- integrity sha512-aoGxanpFPLg7MkIl/DDFYtb0iWz7jMFGqFhvEDZga6/4QTjneiD8I/NXL1x5aaoCp7FSIT6h/OhykDdPsbtMig==
- dependencies:
- camel-case "^3.0.0"
- clean-css "^4.2.1"
- commander "^2.19.0"
- he "^1.2.0"
- param-case "^2.1.1"
- relateurl "^0.2.7"
- uglify-js "^3.5.1"
-
html-tags@^1.0.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/html-tags/-/html-tags-1.2.0.tgz#c78de65b5663aa597989dd2b7ab49200d7e4db98"
@@ -4260,11 +4233,6 @@ minimist@^1.1.3, minimist@^1.2.0:
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284"
integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=
-minimist@~0.0.1:
- version "0.0.10"
- resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf"
- integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=
-
minipass@2.3.5:
version "2.3.5"
resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.5.tgz#cacebe492022497f656b0f0f51e2682a9ed2d848"
@@ -4472,11 +4440,6 @@ needle@^2.2.1:
iconv-lite "^0.4.4"
sax "^1.2.4"
-neo-async@^2.6.0:
- version "2.6.1"
- resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c"
- integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==
-
nice-try@^1.0.4:
version "1.0.5"
resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366"
@@ -4800,14 +4763,6 @@ opn@^5.1.0:
dependencies:
is-wsl "^1.1.0"
-optimist@^0.6.1:
- version "0.6.1"
- resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686"
- integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY=
- dependencies:
- minimist "~0.0.1"
- wordwrap "~0.0.2"
-
optionator@^0.8.1:
version "0.8.2"
resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64"
@@ -4913,13 +4868,6 @@ pako@~1.0.5:
resolved "https://registry.yarnpkg.com/pako/-/pako-1.0.10.tgz#4328badb5086a426aa90f541977d4955da5c9732"
integrity sha512-0DTvPVU3ed8+HNXOu5Bs+o//Mbdj9VNQMUOe9oKCwh8l0GNwpTDMKCWbRjgtD291AWnkAgkqA/LOnQS8AmS1tw==
-param-case@^2.1.1:
- version "2.1.1"
- resolved "https://registry.yarnpkg.com/param-case/-/param-case-2.1.1.tgz#df94fd8cf6531ecf75e6bef9a0858fbc72be2247"
- integrity sha1-35T9jPZTHs915r75oIWPvHK+Ikc=
- dependencies:
- no-case "^2.2.0"
-
parcel-bundler@^1.12.3:
version "1.12.3"
resolved "https://registry.yarnpkg.com/parcel-bundler/-/parcel-bundler-1.12.3.tgz#2bbf70bfa2d06097f071653285040bd125684d09"
@@ -5059,6 +5007,11 @@ path-key@^2.0.0, path-key@^2.0.1:
resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40"
integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=
+path-key@^3.1.0:
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.0.tgz#99a10d870a803bdd5ee6f0470e58dfcd2f9a54d3"
+ integrity sha512-8cChqz0RP6SHJkMt48FW0A7+qUOn+OsnOsVtzI59tZ8m+5bCSk7hzwET0pulwOM2YMn9J1efb07KB9l9f30SGg==
+
path-parse@^1.0.6:
version "1.0.6"
resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c"
@@ -5918,11 +5871,6 @@ regjsparser@^0.6.0:
dependencies:
jsesc "~0.5.0"
-relateurl@^0.2.7:
- version "0.2.7"
- resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9"
- integrity sha1-VNvzd+UUQKypCkzSdGANP/LYiKk=
-
remove-array-items@^1.0.0:
version "1.1.1"
resolved "https://registry.yarnpkg.com/remove-array-items/-/remove-array-items-1.1.1.tgz#fd745ff73d0822e561ea910bf1b401fc7843e693"
@@ -6382,7 +6330,7 @@ source-map-url@^0.4.0:
resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3"
integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=
-source-map@0.6.1, source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1:
+source-map@0.6.1, source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==
@@ -6929,14 +6877,6 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
-uglify-js@^3.1.4, uglify-js@^3.5.1:
- version "3.6.0"
- resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5"
- integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg==
- dependencies:
- commander "~2.20.0"
- source-map "~0.6.1"
-
uid-safe@^2.1.5:
version "2.1.5"
resolved "https://registry.yarnpkg.com/uid-safe/-/uid-safe-2.1.5.tgz#2b3d5c7240e8fc2e58f8aa269e5ee49c0857bd3a"
@@ -7232,11 +7172,6 @@ wide-align@^1.1.0:
dependencies:
string-width "^1.0.2 || 2"
-wordwrap@~0.0.2:
- version "0.0.3"
- resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107"
- integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc=
-
wordwrap@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb"