sankunginfochild.vue 508 B

1234567891011121314151617181920212223242526272829
  1. <template>
  2. <div>
  3. <iframe style="border:none" :src='srcs' width="100%" :height="heights"></iframe>
  4. </div>
  5. </template>
  6. <script>
  7. export default {
  8. props:['src','height'],
  9. data () {
  10. return {
  11. srcs:'',
  12. heights:0
  13. }
  14. },
  15. watch:{
  16. src(){
  17. this.srcs = this.src;
  18. }
  19. },
  20. created(){
  21. this.srcs = this.src;
  22. this.heights = this.height;
  23. console.log(this.srcs);
  24. }
  25. }
  26. </script>
  27. <style>
  28. </style>