1
0
mirror of https://github.com/flarum/core.git synced 2025-08-01 14:10:37 +02:00

Initial refactor of client actions, data preloading, SEO

An initial stab at flarum/core#126. Still WIP. Preliminary
implementation of flarum/core#128 and flarum/core#13.
This commit is contained in:
Toby Zerner
2015-07-07 15:29:21 +09:30
parent fcc5aa17ea
commit 99876e9e36
27 changed files with 413 additions and 241 deletions

View File

@@ -15,8 +15,17 @@ class App {
this.initializers.toArray().forEach((initializer) => initializer(this));
}
preloadedDocument() {
if (app.preload.document) {
const results = app.store.pushPayload(app.preload.document);
app.preload.document = null;
return results;
}
}
setTitle(title) {
document.title = (title ? title+' - ' : '')+this.config['forum_title'];
document.title = (title ? title+' - ' : '')+this.forum.attribute('title');
}
request(options) {