File tree Expand file tree Collapse file tree 2 files changed +19
-18
lines changed
Expand file tree Collapse file tree 2 files changed +19
-18
lines changed Original file line number Diff line number Diff line change @@ -197,7 +197,9 @@ export const setupIonicReact = (config: IonicConfig = {}) => {
197197 * TODO: Remove when all integrations have been
198198 * migrated to CE build.
199199 */
200- document . documentElement . classList . add ( 'ion-ce' ) ;
200+ if ( typeof ( document as any ) !== 'undefined' ) {
201+ document . documentElement . classList . add ( 'ion-ce' ) ;
202+ }
201203
202204 initialize ( {
203205 ...config
Original file line number Diff line number Diff line change @@ -21,24 +21,23 @@ const getHelperFunctions = () => {
2121export const IonicVue : Plugin = {
2222
2323 async install ( _ : App , config : IonicConfig = { } ) {
24- if ( typeof ( window as any ) !== 'undefined' ) {
25-
26- /**
27- * By default Ionic Framework hides elements that
28- * are not hydrated, but in the CE build there is no
29- * hydration.
30- * TODO: Remove when all integrations have been
31- * migrated to CE build.
32- */
24+ /**
25+ * By default Ionic Framework hides elements that
26+ * are not hydrated, but in the CE build there is no
27+ * hydration.
28+ * TODO: Remove when all integrations have been
29+ * migrated to CE build.
30+ */
31+ if ( typeof ( document as any ) !== 'undefined' ) {
3332 document . documentElement . classList . add ( 'ion-ce' ) ;
34-
35- const { ael, rel, ce } = getHelperFunctions ( ) ;
36- initialize ( {
37- ...config ,
38- _ael : ael ,
39- _rel : rel ,
40- _ce : ce
41- } ) ;
4233 }
34+
35+ const { ael, rel, ce } = getHelperFunctions ( ) ;
36+ initialize ( {
37+ ...config ,
38+ _ael : ael ,
39+ _rel : rel ,
40+ _ce : ce
41+ } ) ;
4342 }
4443} ;
You can’t perform that action at this time.
0 commit comments