随笔分类 -  Javascript

1 2 下一页
相关代码学习心得
Failed to load config "react-app" to extend from.
摘要:使用yarn v2 安装create-react-app后,使用yarn strat启动出现问题Failed to load config "react-app" to extend from.Referenced from: /home/rudy/projects/webstorm/my-app/ 阅读全文
posted @ 2021-04-18 22:27 c3tc3tc3t 阅读(3363) 评论(0) 推荐(2)
YarnV2 install
摘要:npm install -g yarn@berry https://github.com/yarnpkg/berry/issues/719 阅读全文
posted @ 2021-04-18 16:15 c3tc3tc3t 阅读(116) 评论(0) 推荐(0)
ou can mix require and export. You can't mix import and module.exports.
摘要:ou can mix require and export. You can't mix import and module.exports. 阅读全文
posted @ 2019-05-22 16:34 c3tc3tc3t 阅读(253) 评论(0) 推荐(0)
vue框架之自定义组件中使用v-model
摘要:通常 vue在html常见表单空间支持v-model双向绑定例如 1,当我们自定义组件时如何使用v-model? 答:代码实例如下 2 我们在自定义组件中使用v-model的目的是什么? 答:自定义模板上定义v-mode目的是向外传递值,也就是向他的父组件传递值,影响父组件的属性,通过父组件的属性初 阅读全文
posted @ 2019-03-08 16:19 c3tc3tc3t 阅读(2042) 评论(0) 推荐(0)
react config test env with jest and create-react-app 1
摘要:/.babelrc /jest.config.js /package.json /tests/setup.js 阅读全文
posted @ 2018-10-29 13:43 c3tc3tc3t 阅读(409) 评论(0) 推荐(0)
vue测试安装和配置
摘要:配置 webpack.base.conf.js .babelrc.js test/steup.js package.json package.json 阅读全文
posted @ 2018-04-20 11:36 c3tc3tc3t 阅读(208) 评论(0) 推荐(0)
Vue单文件模板实例
摘要:AddItemComponent.vue ChangeTitleComponenet.vue ItemComponent.vue ItemsComponent.vue App.vue main.js index.html 阅读全文
posted @ 2018-02-10 16:16 c3tc3tc3t 阅读(393) 评论(0) 推荐(0)
很乱,临时保存,自定义v-model
摘要:1 2 3 4 5 6 learn1 7 8 9 10 11 12 {{msg}} {{user}} 13 14 15 16 17 18 19 20 21 ... 阅读全文
posted @ 2018-02-10 12:37 c3tc3tc3t 阅读(281) 评论(0) 推荐(0)
使用vue的v-model自定义 checkbox组件
摘要:1 2 3 4 5 Vue.component('my-checkbox', { 6 template:'#c', 7 model: { 8 prop: 'checked', 9 event: 'change' //要触发的事件 10 }, 11 props: { 12 checked:Bool... 阅读全文
posted @ 2018-02-09 20:52 c3tc3tc3t 阅读(3373) 评论(0) 推荐(0)
webpack使用 babili-webpack-plugin 报错 "original.line and original.column are not numbers"
摘要:按照这个解决 https://github.com/chentsulin/electron-react-boilerplate/issues/1300 changing "babili-webpack-plugin": "^0.1.2" to "babili-webpack-plugin": "0. 阅读全文
posted @ 2018-01-13 20:58 c3tc3tc3t 阅读(577) 评论(0) 推荐(0)
casperjs问题收集
摘要:1 无妨访问某些页面可能是ssl选项没有使用 阅读全文
posted @ 2018-01-08 17:39 c3tc3tc3t 阅读(141) 评论(0) 推荐(0)
解决emacs配置tern报错`tern-reparse-on-idle':
摘要:使用Nodejs安装完tern后,在/user/local/bin建立软连接 阅读全文
posted @ 2018-01-01 22:24 c3tc3tc3t 阅读(393) 评论(0) 推荐(0)
翻译:WebAssembly简介:我们为什么要关心这个技术? ​​​​
摘要:原文: https://tomassetti.me/introduction-to-webassembly/ WebAssembly简介:我们为什么要关心这个技术? ​​​​ 在对抗js的伟大战斗中有一个新的武器,允许开发者们在提高性能和生产力同时选择他们喜欢的编程风格。这个武器就是WebAssem 阅读全文
posted @ 2017-12-20 23:57 c3tc3tc3t 阅读(542) 评论(0) 推荐(0)
javascript箭头函数
摘要:原文 https://thewebjuice.com/es6-arrows/ 1 使用es6箭头定义匿名函数 es5 2 单个参数和多个参数 es5 3定义闭包 es5 4 Literal Syntax es5 阅读全文
posted @ 2017-09-23 08:57 c3tc3tc3t 阅读(176) 评论(0) 推荐(0)
graphql pass arg
摘要:var numSides = 6; var numRolls = 3; var xhr = new XMLHttpRequest(); xhr.responseType = 'json'; xhr.open("POST", "http://localhost:4000/graphql"); xhr.setRequestHeader("Content-Type", "application/jso... 阅读全文
posted @ 2017-09-18 15:21 c3tc3tc3t 阅读(168) 评论(0) 推荐(0)
如何调用npm已经安装在全局位置的模块
摘要:参考链接 https://nodejs.org/api/modules.html#modules_loading_from_the_global_folders npm install xxx -g通常安装在全局目录 在你的bashrc或者zashrc中导出全局目录 在你的package.json中 阅读全文
posted @ 2017-08-31 22:10 c3tc3tc3t 阅读(2076) 评论(0) 推荐(0)
网站用户行为数据统计与分析之一:埋点代码设计
摘要:原文:http://www.aiuxian.com/article/p-1442657.html 代码分析: 此段代码也不难理解,有几个地方我捎带讲解一下: uuid,在这里我把它定为用户访问唯一标识符,更多有关uuid的资料,大家上网查。 _utmc,用来标识一段时间内,如果用户不断刷新,我们算一 阅读全文
posted @ 2016-06-05 11:42 c3tc3tc3t 阅读(1109) 评论(2) 推荐(0)
window和nodejs作用域区别(待续)
摘要://这是在浏览器环境下,chrome下var n =2 ;var obj={n:4,fn1:(function(){console.log("fn1->this ="+this); //这里立即执行时,this是windowconsole.log("fn1->this.n = "+this.n); ... 阅读全文
posted @ 2015-12-24 14:21 c3tc3tc3t 阅读(474) 评论(0) 推荐(0)
javascript代码注意事项
摘要:1 代码行末要加分好。原因>2 初始化变量应该加上默认值因为使用typeof时 未声明和声明为初始化的值都返回undefined,如果规定都要初始化,得到undefined,就知道没有声明var message;alert(typeof message) //undefinedalert(typeo... 阅读全文
posted @ 2015-12-03 21:56 c3tc3tc3t 阅读(189) 评论(0) 推荐(0)
一个选择器工具。测试结构伪类选择器方法
摘要:http://lea.verou.me/demos/nth.html 阅读全文
posted @ 2015-11-19 21:27 c3tc3tc3t 阅读(216) 评论(0) 推荐(0)

1 2 下一页