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

直接使用tt.xx会报错找不到名称“tt” #16934

Open
zhaowei97 opened this issue Nov 27, 2024 · 3 comments
Open

直接使用tt.xx会报错找不到名称“tt” #16934

zhaowei97 opened this issue Nov 27, 2024 · 3 comments

Comments

@zhaowei97
Copy link

相关平台

字节跳动小程序

小程序基础库: 3.44.0.12
使用框架: React

复现步骤

直接使用tt.pay就会重现

期望结果

解决飘红问题

实际结果

tt对象飘红

环境信息

 Taro CLI 3.6.35 environment info:
    System:
      OS: Windows 10 10.0.19045
    Binaries:
      Node: 16.8.0 - C:\Program Files\nodejs\node.EXE  
      Yarn: 1.22.22 - C:\Program Files\nodejs\yarn.CMD 
      npm: 7.21.0 - C:\Program Files\nodejs\npm.CMD    
    npmPackages:
      @tarojs/cli: 3.6.35 => 3.6.35 
      @tarojs/components: 3.6.35 => 3.6.35 
      @tarojs/helper: 3.6.35 => 3.6.35 
      @tarojs/plugin-framework-react: 3.6.35 => 3.6.35 
      @tarojs/plugin-html: 3.6.35 => 3.6.35 
      @tarojs/plugin-platform-alipay: 3.6.35 => 3.6.35 
      @tarojs/plugin-platform-h5: 3.6.35 => 3.6.35     
      @tarojs/plugin-platform-jd: 3.6.35 => 3.6.35     
      @tarojs/plugin-platform-qq: 3.6.35 => 3.6.35     
      @tarojs/plugin-platform-swan: 3.6.35 => 3.6.35
      @tarojs/plugin-platform-tt: 3.6.35 => 3.6.35
      @tarojs/plugin-platform-weapp: 3.6.35 => 3.6.35
      @tarojs/react: 3.6.35 => 3.6.35
      @tarojs/runtime: 3.6.35 => 3.6.35
      @tarojs/shared: 3.6.35 => 3.6.35
      @tarojs/taro: 3.6.35 => 3.6.35
      @tarojs/taro-loader: 3.6.35 => 3.6.35
      @tarojs/webpack5-runner: 3.6.35 => 3.6.35
      babel-preset-taro: 3.6.35 => 3.6.35
      eslint-config-taro: 3.6.35 => 3.6.35
      react: ^18.0.0 => 18.3.1
@yclnycl
Copy link

yclnycl commented Nov 27, 2024

有异常吗 是编译错误还是idea标红

This was referenced Nov 30, 2024
@zhaowei97
Copy link
Author

@yclnycl 不影响工程运行 单纯vscode飘红

@yclnycl
Copy link

yclnycl commented Dec 2, 2024

@yclnycl 不影响工程运行 单纯vscode飘红

是eslint的规则问题 你可以当前行加eslint-disable-next-line no-undef规则注释这样就不飘红了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants