${i18n.__('home.temp_left')}
-${i18n.__('home.temp_right')}
-diff --git a/app/views/home/controller.js b/app/views/home/controller.js
index e47c963..7ba5dac 100644
--- a/app/views/home/controller.js
+++ b/app/views/home/controller.js
@@ -5,11 +5,8 @@ export class HomeController extends ViewController {
// Super passes state, view name, and default state to ViewController,
// which stores state in this.appState and the view controller's state to this.state
super(state, 'home', {
- messages: [
- 'hello',
- 'test',
- 'yay',
- ],
+ recentReviews: [],
+ recentUpdates: [],
});
// If using controller methods in an input's onchange or onclick instance,
@@ -17,7 +14,10 @@ export class HomeController extends ViewController {
// or use `onclick=${() => controller.submit()}` to maintain the 'this' of the class instead.
}
- get messages() {
- return [...this.state.messages];
+ get recentReviews() {
+ return [...this.state.recentReviews];
+ }
+ get recentUpdates() {
+ return [...this.state.recentUpdates];
}
}
\ No newline at end of file
diff --git a/app/views/home/index.js b/app/views/home/index.js
index a1a1f25..af49c13 100644
--- a/app/views/home/index.js
+++ b/app/views/home/index.js
@@ -1,42 +1,18 @@
import html from 'choo/html';
-import './styles.scss'; // Creates a separate CSS file, but allows better code splitting.
-// We'll see if code splitting is worth it in the end or if we should combine everything into `src/index.scss`
import { HomeController } from './controller'; // The controller for this view, where processing should happen.
+import { loggedOutView } from './loggedOut';
// This is the view function that is exported and used in the view manager.
export const homeView = (state, emit) => {
const controller = new HomeController(state);
- const { i18n } = controller;
// Returning an array in a view allows non-shared parent HTML elements.
// This one doesn't have the problem right now, but it's good to remember.
return [
- html` ${i18n.__('home.temp_left')} ${i18n.__('home.temp_right')} ${message}${i18n.__('home.subtitle')}
-
-
lol wut how are u logged in
` + ), ]; } \ No newline at end of file diff --git a/app/views/home/loggedOut.js b/app/views/home/loggedOut.js new file mode 100644 index 0000000..91824e3 --- /dev/null +++ b/app/views/home/loggedOut.js @@ -0,0 +1,81 @@ +import html from 'choo/html'; + +export const loggedOutView = (homeController, emit) => { + return [ + html`