使用 React 一段时间了,但对 React Native 还很陌生。
我正在使用 tailwind 和https://tailwindcss-react-native.vercel.app/installation
import { View, Text } from "react-native";
import React from "react";
export default function Navigation() {
return (
<View className="grid h-screen w-screen place-items-center">
<Text className="text-red-800">Test</Text>
</View>
);
}
Run Code Online (Sandbox Code Playgroud)
Tailwind 可以工作,文本是红色的,但是我在上面的类名下遇到 TS 错误 ^^
No overload matches this call.
Overload 1 of 2, '(props: ViewProps | Readonly<ViewProps>): View', gave the following error.
Type '{ children: Element; className: string; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<View> & Readonly<ViewProps> & Readonly<{ …Run Code Online (Sandbox Code Playgroud) 我的应用程序是在 Vue 中开发的,目前它在 IE11 和旧版 Edge 中效果不佳,我可以在 Edge 上渲染“请更新您的浏览器屏幕”,因为该应用程序会加载一些,但是 IE11 只显示一个空白屏幕。
如何检查用户是否在 IE11 上,然后只呈现一个纯 HTML/CSS 页面,要求他们更新浏览器?
尝试测试我的 firebase 功能时,我不断收到当前错误。
Found .runtimeconfig.json but the JSON format is invalid.
! TypeError: Cannot read property 'app' of undefined
at Object.<anonymous> (F:\Web Dev Stuff\SEEKIO\seekio\functions\index.js:4:56)
at Module._compile (internal/modules/cjs/loader.js:701:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:712:10)
at Module.load (internal/modules/cjs/loader.js:600:32)
at tryModuleLoad (internal/modules/cjs/loader.js:539:12)
at Function.Module._load (internal/modules/cjs/loader.js:531:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:22:18)
at initializeRuntime (C:\Users\msi\AppData\Roaming\npm\node_modules\firebase-tools\lib\emulator\functionsEmulatorRuntime.js:680:29)
at process._tickCallback (internal/process/next_tick.js:68:7)
! We were unable to load your functions code. (see above)
Run Code Online (Sandbox Code Playgroud)
我的运行时配置如下所示:
当我删除配置文件并运行firebase functions:config:get > .runtimeconfig.json它时,它只会返回这些变量和相同的文件格式,所以我有点困惑。
我的函数如下所示:
const functions = require("firebase-functions");
const admin = require("firebase-admin");
admin.initializeApp();
const …Run Code Online (Sandbox Code Playgroud) json firebase algolia google-cloud-functions google-cloud-firestore
algolia ×1
firebase ×1
javascript ×1
json ×1
react-native ×1
reactjs ×1
tailwind-css ×1
typescript ×1
vue.js ×1