File tree Expand file tree Collapse file tree 5 files changed +10
-9
lines changed Expand file tree Collapse file tree 5 files changed +10
-9
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " voltranjs" ,
3- "version" : " 1.2.0-beta.7 " ,
3+ "version" : " 1.2.0-beta.8 " ,
44 "main" : " src/index.js" ,
55 "author" : " Hepsiburada Technology Team" ,
66 "bin" : {
Original file line number Diff line number Diff line change @@ -124,7 +124,6 @@ async function setInitialStates(renderers) {
124124 const winner = getWinner ( requests , hashes ) ;
125125 incWinnerScore ( winner , hashes ) ;
126126 putWinnerMap ( serviceName , renderer . winnerMap , winner ) ;
127-
128127 if ( ! promises [ winner . hash ] ) {
129128 promises [ winner . hash ] = callback => {
130129 winner
Original file line number Diff line number Diff line change @@ -47,9 +47,7 @@ class App extends PureComponent {
4747 const { isHydratingCompleted } = this . state ;
4848 return (
4949 < ReactRenderContext . Provider value = { isHydratingCompleted } >
50- < div >
51- < Switch > { renderRoutes ( this . generateRoutingProps ( ) ) } </ Switch >
52- </ div >
50+ < Switch > { renderRoutes ( this . generateRoutingProps ( ) ) } </ Switch >
5351 </ ReactRenderContext . Provider >
5452 ) ;
5553 }
Original file line number Diff line number Diff line change @@ -31,16 +31,17 @@ function Html({
3131 isMobileFragment,
3232 context
3333} ) {
34- return `
34+ if ( children ) {
35+ return `
3536 <div>
3637 ${ styleTags }
3738 <script type='text/javascript'>${ generateInitialState ( initialState , componentName ) } </script>
3839 <div
3940 id='${ componentName . replace ( / [ ' " ' ] + / g, '' ) } _${ initialState . id } '
4041 style="pointer-events: none;"
4142 class="${ voltranConfig . prefix } -voltran-body voltran-body ${
42- isMobileFragment ? 'mobile' : ''
43- } ${ fullWidth ? 'full' : '' } ${ componentClassName ( componentName , context ) } ">
43+ isMobileFragment ? 'mobile' : ''
44+ } ${ fullWidth ? 'full' : '' } ${ componentClassName ( componentName , context ) } ">
4445 ${ children }
4546 </div>
4647 <div>REPLACE_WITH_LINKS</div>
@@ -55,6 +56,9 @@ function Html({
5556 `<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0" />`
5657 ) }
5758 </div>` ;
59+ }
60+
61+ return '' ;
5862}
5963
6064export default Html ;
Original file line number Diff line number Diff line change 1- import { useEffect } from 'react' ;
1+ import { useEffect } from 'react' ;
22
33import withBaseComponent from '../../partials/withBaseComponent' ;
44import { getEventBus } from '../../utils/helper' ;
You can’t perform that action at this time.
0 commit comments