Skip to content

Instantly share code, notes, and snippets.

一波不是一波 riskers

Block or report user

Report or block riskers

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@riskers
riskers / .dockerignore
Last active Mar 11, 2019
eggjs Dockerfile + gitlab ci
View .dockerignore
app/**/*.js
test/**/*.js
config/**/*.js
app/**/*.map
test/**/*.map
config/**/*.map
@riskers
riskers / git-flow.md
Created Apr 12, 2017 — forked from yesmeck/git-flow.md
Git 开发流程
View git-flow.md

Git 协作流程

master 分支

master 永远处于稳定状态,这个分支代码可以随时用来部署。不允许在该分支直接提交代码。

develop 分支

开发分支,包含了项目最新的功能和代码,所有开发都在 develop 上进行。一般情况下小的修改直接在这个分支上提交代码。

View default.custom.yaml
# Rime default settings
# encoding: utf-8
patch:
config_version: "0.38"
schema_list:
# - schema: luna_pinyin
- schema: luna_pinyin_simp
# - schema: luna_pinyin_fluency
# - schema: bopomofo
@riskers
riskers / main.md
Last active Feb 2, 2019
关于 websocket 心跳的一些记录
View main.md

长连接为什么要保持心跳?

websocket心跳是为了让 client 告诉 server 『我还活着,没有掉线』而存在的,否则 server 可能会断掉连接。

国内移动无线网络运营商在链路上一段时间内没有数据通讯后, 会淘汰NAT表中的对应项, 造成链路中断。而国内的运营商一般NAT超时的时间为5分钟,所以通常我们心跳设置的时间间隔为3-5分钟。

一般是 client send ping ,server 返回 pong 保持心跳。

var heartCheck = {
@riskers
riskers / Column.dart
Last active Jan 23, 2019
Flutter Note Code
View Column.dart
import 'package:flutter/material.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
// TODO: implement build
return MaterialApp(
title: 'Fultter',
@riskers
riskers / redux-combine.dart
Last active Jan 17, 2019
flutter redux demo
View redux-combine.dart
// https://github-riskers-blog.oss-cn-qingdao.aliyuncs.com/20190117210031.gif
import 'package:flutter/material.dart';
import 'package:redux/redux.dart';
import 'package:redux_thunk/redux_thunk.dart';
import 'package:flutter_redux/flutter_redux.dart';
class AppState {
final int count;
final int clickCount;
@riskers
riskers / function_widget.dart
Last active Jan 12, 2019
flutter 组件化
View function_widget.dart
import 'package:flutter/material.dart';
Widget helloRect() {
return Container(
color: Colors.purple,
width: 200,
height: 200,
margin: EdgeInsets.all(16),
child: Center(child: Text('Hi')),
);
@riskers
riskers / rxjs-diagrams.md
Created Dec 14, 2018 — forked from PCreations/rxjs-diagrams.md
Super Intuitive Interactive Diagrams to learn combining RxJS sequences by Max NgWizard K
@riskers
riskers / README.md
Last active Sep 27, 2018
wxapp 踩坑日志
View README.md
  1. tabBarselectedIconPath 必须设置,否则:

尺寸最好为 81 * 81

  1. navigationStyle: "custom" 时可以自定义导航栏,然后如果需要设置返回键,需要设置 topstatusBarHeight + 10:

10 是经验值,是指胶囊键据屏幕上边缘的距离

@riskers
riskers / main.md
Created Sep 26, 2018
wordpress 开发
View main.md
| - your-theme
  | - images              # 主题相关图片资源
  | - header.php          # html 头部模板
  | - footer.php          # html 尾部模板
  | - index.php           # 首页模板
  | - single.php          # 文章模板
  | - page.php            # 页面模板
  | - style.css           
You can’t perform that action at this time.