소스 검색

content can now be placed in router_frame

Rodja Trappe 2 년 전
부모
커밋
49f8ae62d8
2개의 변경된 파일1개의 추가작업 그리고 2개의 파일을 삭제
  1. 0 1
      examples/single_page_app/main.py
  2. 1 1
      examples/single_page_app/router_frame.js

+ 0 - 1
examples/single_page_app/main.py

@@ -30,5 +30,4 @@ with ui.row():
 # this places the frame for the content which should be displayed
 router.frame().classes('w-full pt-8')
 
-
 ui.run()

+ 1 - 1
examples/single_page_app/router_frame.js

@@ -1,5 +1,5 @@
 export default {
-  template: `<div>Test</div>`,
+  template: `<div><slot></slot></div>`,
   mounted() {
     window.addEventListener("popstate", (event) => {
       if (event.state && event.state.page) {