我使用react-native init 创建了一个应用程序,并且工作正常,直到我尝试开始使用expo 在我的手机上测试它。
尝试使用 expo (npx expo start) 启动应用程序,我有:
Developer tools running on http://localhost:19002
Opening developer tools in the browser...
Some dependencies are incompatible with the installed expo package version:
- @react-native-community/slider - expected version: 4.1.7 - actual version installed: 4.1.10
Your project may not work correctly until you install the correct versions of the packages.
To install the correct versions of these packages, please run: expo install [package-name ...]
Starting Metro Bundler
Error: Problem validating fields in app.json. …Run Code Online (Sandbox Code Playgroud) 使用knockout.js(和敲除验证)我有这个:
self.nickname = ko.observable("").extend({
required: true,
minLength: 3
});
Run Code Online (Sandbox Code Playgroud)
和
<input type="text" data-bind="value: nickname" class="short" maxlength="30" />
<div class="formRow rowErrorMsg" data-bind="visible: nickname.isValid() == false"><span class="staticImages staticImagesError"></span> <?php text("Enter a valid username") ?></div>
Run Code Online (Sandbox Code Playgroud)
但问题是,当"昵称"无效时,请在输入控件旁边输入一个文本.带有错误消息的DIV开始可见,然后正常工作.
我需要这样做: