springboot2
springboot集成redis下载redis的windows安装包并安装 下载地址:https://github.com/MicrosoftArchive/redis/releases 安装就一路next,然后找到安装redis的目录,新建start.bat,并写入:redis-server.exe redis.windows.conf 点击start.bat启动(退出redis命令:Ctrl+c) 安装redis客户端Redis Desktop Manager 下载地址: https://pan.baidu.com/s/1Jvr9MbgFn4UJh4M1AMo3gA 提取码:3i9b 安装就一路next,然后先启动redis,然后,打开客户端 代码编写 新建StudentController类,并写入:package com.dj.app.springboot.web;import com.dj.app.springboot.service.StudentService;import org.springframework.beans.factory.annotati...
springboot
springboot学习所遇问题springboot项目中,右侧没有mavenproject 输入命令:shift + ctrl + A, 在输入Maven,选择ADD 设置maven镜像 在settings -> Build,Execution,Deployment -> Maven, 找到Maven home directory,打开该目录 找到conf/settings.xml, 在mirrors下写入以下内容:<mirrors> <mirror> <id>nexus-aliyun</id> <mirrorOf>*</mirrorOf> <name>Nexus aliyun</name> <url>http://maven.aliyun.com/nexus/content/groups/public</url> </mirror></mirrors> 更新jar包的最新版本 ...
uni-app中nvue的开发心得
介绍 uni-app App端内置了一个基于 weex 改进的原生渲染引擎,提供了原生渲染能力。 在App端,如果使用vue页面,则使用webview渲染;如果使用nvue页面(native vue的缩写),则使用原生渲染。一个App中可以同时使用两种页面,比如首页使用nvue,二级页使用vue页面,hello uni-app示例就是如此。 虽然nvue也可以多端编译,输出H5和小程序,但nvue的css写法受限,所以如果你不开发App,那么不需要使用nvue。 使用场景 需要高性能的区域长列表或瀑布流滚动。webview的页面级长列表滚动时没有性能问题的(就是滚动条覆盖webview整体高度),但页面中某个区域做长列表滚动,则需要使用nvue的list、recycle-list、waterfall等组件。这些组件的性能要高于vue页面里的区域滚动组件scroll-view。 复杂高性能的自定义下拉刷新。uni-app的pages.json里可以配置原生下拉刷新,但引擎内置的下拉刷新样式只有雪花和circle圈2种样式。如果你需要自己做复杂的下拉刷新,推荐使用nvue的ref...
uni-app开发总结
开发环境搭建下载HBuilderX 下载地址:https://www.dcloud.io/hbuilderx.html 安装插件 打开菜单: 工具 > 插件安装,安装以下插件 App真机运行 es6编译 eslint-js eslint-plugin-vue less编译 scss/sass编译 stylus编译 uni-app App调试 uni-app编译 uni-app的开发总结条件编译写法:以 #ifdef 或 #ifndef 加 %PLATFORM% 开头,以 #endif 结尾。 #ifdef:if defined 仅在某平台存在 #ifndef:if not defined 除了某平台均存在 %PLATFORM%:平台名称 详细文档请看:https://uniapp.dcloud.io/platform?id=%e6%9d%a1%e4%bb%b6%e7%bc%96%e8%af%91 适配uni-app 支持的通用 css 单位包括 px、rpx px 即屏幕像素 rpx 即响应式px,一种根据屏幕宽度自适应的动态单位。以750宽的屏幕为...
uni-app问题收集及解决
css部分nvue支持sass但是不支持sass的嵌套 变量使用(支持) <style lang="scss"> $lineBorderColor: yellow; .icon_right{ font-size: 50px; color: $lineBorderColor; }</style> 外部scss文件引入(支持) <style lang="scss"> @import "../../constant/css/constant.scss"; .icon_right{ font-size: 50px; color: $lineBorderColor; }</style> nvue不支持sass嵌套 nvue支持sass的所有其他属性,举例mixin(混合) // constant.scss文件$lineBorderColor: #dfdfdf;@mixin my { just...
react native日常开发遇到的问题
react-native navigationOptions中不能获取this、state场景:在createStackNavigator路由过来的页面,navigationOptions的header中添加搜索框 如下图: static navigationOptions = { headerStyle: {backgroundColor: '#0086f1'}, headerTitle: ( <TextInput placeholder={'请输入搜索内容'} onChangeText={(text) => this.setState({'str': text})};constructor(props) { super(props); this.state = ({ str: '' })...
react-native开发总结——常用插件
多环境配置react-native-config 详细文档请看: https://github.com/luggit/react-native-config 下载安装包: 当前版本(“react-native-config”: “^1.3.1”) yarn add react-native-config 连接库: (react-native 0.60版本后可以不执行这个命令) npx react-native link react-native-config ios端需要连接库: 在当前项目下进入ios目录, 执行:pod install android端链接库: 在当前项目下的android/settings.gradle添加: include ':react-native-config'project(':react-native-config').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-c...
react-native开发总结——react-navigation
介绍 react-navigation 路由导航(用于页面跳转, 4.x的版本)包括:createStackNavigator:页面跳转的路由导航createSwitchNavigator:底部tabbarcreateDrawerNavigator:抽屉侧边栏导航 createStackNavigator:页面跳转的路由导航使用步骤核心包:react-navigation npm install react-navigation 依赖项目: npm install react-native-reanimated react-native-gesture-handler react-native-screens react-native-safe-area-context @react-native-community/masked-view 使用createStackNavigator 基础导航器 前置安装 npm install react-navigation-stac...
react-native开发总结
开发环境的搭建下载jdk 下载地址: https://www.oracle.com/java/technologies/javase-downloads.html 注意:推荐下载jdk1.8及以上的版本,下载之后配置环境变量 下载android studo 下载地址: https://developer.android.google.cn/studio/ android studo推荐使用3.5以上的版本,然后下载android sdk,选择8.1以上的版本 创建react-native项目 输入命令:npx react-native init myproject 分辨率的适配, Dimensions 详细代码如下: import { Dimensions, View } from 'react-native'// 适配方案export const sumPx = { dpi: (w) => { // 自适应px, 750为设计稿的宽度 return wid...







