Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

failed to resolve component:PageContainer #12004

Closed
yeahjsen opened this issue Jun 28, 2022 · 4 comments
Closed

failed to resolve component:PageContainer #12004

yeahjsen opened this issue Jun 28, 2022 · 4 comments
Labels
F-vue3 Framework - Vue 3 T-weapp Target - 编译到微信小程序 V-3 Version - 3.x

Comments

@yeahjsen
Copy link

相关平台

微信小程序

小程序基础库: 2.24.5
使用框架: Vue 3

复现步骤

页面直接使用,微信开发者工具
vendors.js:3342 [Vue warn]: Failed to resolve component: PageContainer
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
at
at

期望结果

实现微信pageContainer效果

实际结果

微信开发者工具 failed to resolve

环境信息

👽 Taro v3.3.8

Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating

  Taro CLI 3.3.8 environment info:
    System:
      OS: Windows 10
    Binaries:
      Node: 14.17.3 - C:\Program Files\nodejs\node.EXE
      Yarn: 1.22.10 - C:\Program Files\nodejs\yarn.CMD
      npm: 6.14.13 - C:\Program Files\nodejs\npm.CMD  
@taro-bot2 taro-bot2 bot added F-vue3 Framework - Vue 3 T-weapp Target - 编译到微信小程序 V-3 Version - 3.x labels Jun 28, 2022
@Chen-jj
Copy link
Contributor

Chen-jj commented Jun 28, 2022

这只是 warning,不代表不能用吧

@yeahjsen
Copy link
Author

yeahjsen commented Jun 28, 2022

warning里报PageContainer没有解析出来,这用不了了吧

@Chen-jj
Copy link
Contributor

Chen-jj commented Jun 29, 2022

@yeahjsen Taro v3.4.12 没有复现

<template>
  <view>
    <page-container :show="isShow" @clickoverlay="hc">
      <view style='height: 200px'>
        page-container
      </view>
    </page-container>
    <button @tap="hc">toggle</button>
  </view>
</template>

<script>
import Taro from '@tarojs/taro'

export default {
  name: 'ws-carema',
  data: () => {
    return {
      isShow: false
    }
  },
  methods: {
    hc () {
      this.isShow = !this.isShow
    },
  },
}
</script>

image

@Chen-jj Chen-jj closed this as completed Jun 29, 2022
@yeahjsen
Copy link
Author

lQLPJxZy48G3lyfNAofNBniwnyfhRSSwbHkCvU0yhcAGAA_1656_647
lQLPJxZy48G3lxvNA1PNAu-wYzsTrIFUXjwCvU0yh0CHAA_751_851
只能说是版本问题,提交的issue里taro版本是3.3.8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-vue3 Framework - Vue 3 T-weapp Target - 编译到微信小程序 V-3 Version - 3.x
Projects
None yet
Development

No branches or pull requests

2 participants