fixed all eslint errors and warning, compiled as PROD
This commit is contained in:
@@ -21,12 +21,12 @@ export default {
|
||||
}
|
||||
},
|
||||
beforeMount() {
|
||||
// console.log('MainContent beforeMount this.html', this.html);
|
||||
if(!this.home_template_src){
|
||||
// console.log('no home_template_src');
|
||||
if(this.html && this.isfront){ // if html prop is available and we are landing on home then record it has data
|
||||
// console.log('MainContent beforeMount this.html', this.html)
|
||||
if (!this.home_template_src) {
|
||||
// console.log('no home_template_src')
|
||||
if (this.html && this.isfront) { // if html prop is available and we are landing on home then record it has data
|
||||
this.home_template_src = this.html
|
||||
}else{ // else get it from ajax (e.g. if we didn't load the page from home)
|
||||
} else { // else get it from ajax (e.g. if we didn't load the page from home)
|
||||
this.getHomeHtml()
|
||||
}
|
||||
}
|
||||
@@ -35,10 +35,10 @@ export default {
|
||||
getHomeHtml(){
|
||||
MA.get('materio_home/ajax/gethome')
|
||||
.then(({data}) => {
|
||||
// console.log('Home getHomeHtml data', data);
|
||||
// console.log('Home getHomeHtml data', data)
|
||||
this.home_template_src = data.rendered // record the html src into data
|
||||
})
|
||||
.catch(( error ) => {
|
||||
.catch((error) => {
|
||||
console.warn('Issue with getHomeHtml', error)
|
||||
})
|
||||
}
|
||||
|
Reference in New Issue
Block a user