30秒学会 Golang 片段 – Map
Returns a new slice populated with the results of calling the provided function on every element in ...
Returns a new slice populated with the results of calling the provided function on every element in ...
Returns the first key in the provided dictionary that has the given value. Use dictionary.items() an...
Initializes a 2D list of given width and height and value. Use list comprehension and range() to gen...
Replaces all but the last n characters in a string with the specified mask character. Use string.Sub...
Creates a shadow box around the text when it is hovered. display: inline-block to set width and leng...
Returns the scroll position of the current page. Use pageXOffset and pageYOffset if they are defined...
Creates a bouncing loader animation. @keyframes defines an animation that has two states, where the ...
Removes an event listener from an element. Use EventTarget.removeEventListener() to remove an event ...
Returns the difference between two arrays, after applying the provided function to each array elemen...
A hook that returns if the client is online or offline. Create a function, getOnLineStatus, that use...