doodlewind / jshistory-cn Goto Github PK
View Code? Open in Web Editor NEW🇨🇳 《JavaScript 二十年》中文版
Home Page: https://cn.history.js.org
🇨🇳 《JavaScript 二十年》中文版
Home Page: https://cn.history.js.org
问题:在 “语言诞生” 章节中,“微软 JScript” 小节在右侧目录中展示的标题,连同其脚注序号 “22” 也一起展示出来,表现为 “微软 JScript22” 字样,一开始我还误以为是微软 JScript 的 v22 版本。
建议:建议生成目录时自动识别并去掉脚注的标识。
这个问题在 Google Chrome 上不存在。
我在 webcompat 报告了这一问题( webcompat/web-bugs#74843 ),他们发现脚本中显式地滚动到了开头。
插眼
https://github.com/doodlewind/js-20-years-cn/blob/master/part-2.md#%E6%B5%8F%E8%A7%88%E5%99%A8%E5%8D%9A%E5%BC%88%E8%AE%BA 浏览器博弈论 上面的代码有误
即
// 使用模块模式定义 services
var Services = function () {
var privateJobCount = 0; // 「模块」的私有状态
return { // 命名空间对象
jobCount: function {return privateJobCount},
job1: function() {this.jobCount++}
}
}(); // Services 被初始化为调用该函数时的返回值
// 从命名空间里获取实体
Services.job1();
console.log(Services.jobCount()); // 显示 1
首先 jobCount: function {return privateJobCount}
这里 function
后面缺少 ()
其次,应该是 job1: function() {privateJobCount++}
吧?
最终代码是不是这样的?
var Services = function () {
var privateJobCount = 0; // 「模块」的私有状态
return { // 命名空间对象
jobCount: function() {return privateJobCount},
job1: function() {privateJobCount++}
}
}(); // Services 被初始化为调用该函数时的返回值
Services.job1();
console.log(Services.jobCount());
Hi this is a great project. From the readme.md, is part 4 already finished or waiting for translation?
Is it possible to contribute to the translation work (If so, is there guidance for committing?)?
Thanks.
方便阅读
本书纸质版推出时有捐赠社区的承诺,这里维护后续的细节事宜。
本书销量数据在出版社后台可见,基于和出版社之间的版税协议,其金额是透明可追溯的(译者和原作者之间的捐赠协议和出版社无关,故出版社在这一点上没有利益相关)。
目前想法是由译者个人名义按固定期限(如每年)直接捐赠,细节可在此贴出。
首次捐赠暂定年底,届时会更新这个 Issue,如果有更好的想法也欢迎告知!
首先感谢作者的辛苦翻译。
part-1.md#从-mocha-到-spidermonkey 章节图 10. JavaScript 1.2 的新特性
里
- 新数组方法 push, pop, shift, unshift, solice, concat, slice
此处solice
应该是splice
吧
Membranes 是ES6比较隐晦概念,个人感觉到现在也没几个人懂。我也一直没搞懂。中文文献里我也没看过对它的翻译,把它翻译成 隔离层 是不是妥当我不知道,但最好增加下说明。
比如这段 Proxies and WeakMaps were designed, and initially motivated, to support the creation of membranes. Proxies used standalone cannot be transparent, and cannot reasonably approximate transparency. Membranes come reasonably close to transparently emulating a realm boundary. For classes with private members, the emulation is essentially perfect. 本身就比较难懂晦涩了 ,翻译它就难上难。
Proxy 和 WeakMap 的最初设计动机,是支持隔离层的创建。单独使用的 proxy 不可能是透明的,也不能合理地达到接近透明的程度。隔离层能合理且几乎透明地模拟 realm 的边界。对于具备私有成员的类而言,这种模拟基本上是完美的。
另 关于 Membranes 我自己看的比较好理解文档是这篇 What is a membrane?
This wrap-unwrap behavior is precisely what a membrane is.
如题。
RT,是直接提PR么?但是不知道会不会和你的翻译进度有冲突。
《继往开来》 章节,影响观感
建议补个 vh maxheight
The first 说的是第一个20年。开篇标题翻译不太准确,内容吸引力就降低了。
消栈的尾调用 是 指 尾递归么?
学习一个新知识,了解历史,了解来龙去脉,太重要了。完全以一个更高的维度去思考这些新的知识点
原文是 On September 28th 2014 I pushed my first commit to GitHub for a JavaScript library I was working on while studying for my high school exams. 我在复习高中考试的同时提交了 GitHub 上的第一次commit,不是 是为了一个我在高考复习时正在做的 JavaScript 库
Hi! 感谢辛苦的翻译!我最近也从头到尾看完了,亲眼见证最近 Star 数蹭蹭的往上涨,挺激动。
在阅读过程中,也看到了 cn.history.js.org 的正式启动,现在总算有个静态页面咯。
我最近使用的 Pagic 建站工具感觉用来部署这本书的在线版本会很好!
pagic.config.tsx
在根目录 + github actions 就可以持续部署;我自己的一本电子书也已经通过 Pagic 上线咯 -> http://deno-tutorial.js.org。
所以,用 Pagic 来美化界面,怎么样呢?我可以帮忙提交相关 PR,到时候只需要一个简单的合并就好咯。
P.S: 我发现翻译后的文章里大部分标题都没有原文里类似于 5.1.1
这种目录,我也可以帮忙一次性加上,怎么样哈?
期待回复 👍🏿
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.