摘要:
A symbol is a unique and immutable data type that is often used to identify object properties. To create a symbol, you write Symbol() with an optional 阅读全文
摘要:
One particularly useful string method is format. The format method is used to construct strings by inserting values into template strings. Consider th 阅读全文
摘要:
For example we have an object: We shallow copy it: Verify that shallowCopy is not todo: Change text prop of shallowCopy to somethingelse: But if we wa 阅读全文
摘要:
TypeScript’s discriminated union types (aka tagged union types) allow you to model a finite set of alternative object shapes in the type system. The c 阅读全文
摘要:
ES6 class with extends and super: How this is written in ES5: We use 'Tree.call(this)' to pass context, 'this' is refer to Maple because of Clourse. T 阅读全文
摘要:
TypeScript 2.0 introduced the readonly modifier which can be added to a property or index signature declaration. It helps prevent against unintended p 阅读全文
摘要:
# Python's list comprehensions are awesome. vals = [expression for value in collection if condition] # This is equivalent to: vals = [] for value in collection: if condition:... 阅读全文
摘要:
This lesson introduces the --strictNullChecks compiler option and explains how non-nullable types differ from nullable types. It also illustrates how 阅读全文
摘要:
The takeway is to know when we should cache the content? When we should clean the caches? 1. When should cache the content? This should be done in the 阅读全文
摘要:
In this lesson we will use Animated.spring and TouchableWithoutFeedback to animate the scale of a button in our React Native application. We will use 阅读全文