MCPcopy Create free account
hub / github.com/apache/cloudstack / renderError

Function renderError

ui/src/main.js:71–90  ·  view source on GitHub ↗
(err)

Source from the content-addressed store, hash-verified

69vueApp.use(directives)
70
71const renderError = (err) => {
72 console.error('Fatal error during app initialization: ', err)
73 const ErrorComponent = {
74 render: () => h(
75 'div',
76 { style: 'font-family: sans-serif; text-align: center; padding: 2rem;' },
77 [
78 h('h2', { style: 'color: #ff4d4f;' }, 'We\'re experiencing a problem'),
79 h('p', 'The application could not be loaded due to a configuration issue. Please try again later.'),
80 h('details', { style: 'margin-top: 20px;' }, [
81 h('summary', { style: 'cursor: pointer;' }, 'Technical details'),
82 h('pre', {
83 style: 'text-align: left; display: inline-block; margin-top: 10px;'
84 }, 'Missing or malformed config.json. Please ensure the file is present, accessible, and contains valid JSON. Check the browser console for more information.')
85 ])
86 ]
87 )
88 }
89 createApp(ErrorComponent).mount('#app')
90}
91
92fetch('config.json?ts=' + Date.now())
93 .then(response => {

Callers 1

main.jsFile · 0.85

Calls 3

hFunction · 0.85
errorMethod · 0.45
mountMethod · 0.45

Tested by

no test coverage detected