The article “Parse, Don’t Validate” by Alexis King focuses on the concept of type-driven design in programming, emphasizing the use of parsing over validation in handling data. Here’s a simplified summary:
Continue reading Shift to Type-Driven ParsingCategory: Uncategorized
webstorm warning提示改成正紅色
這樣明顯多了,才不會漏看,不然它原本超容易漏看的,因為只有一個 [ 的暗色提示…
Storybook使用
一開始有導航教學還不錯
Meta記載這個component的stories資訊
args可以給它參數
mac難用的問題
記得把Full-Width Alphanumeric Characters 的勾勾取消
用新電腦首先要做什麼
常用git指令
git branch -M main
Linux tutorial
Learning Linux involves understanding various components that range from basic commands to system administration and networking. Here’s a structured outline to guide your learning journey:
1. Basics of Linux
- Introduction to Linux: History, distributions, philosophy.
- Getting Started: Installation of Linux (dual boot or virtual machine), introduction to the GUI and command line interface.
2. Command Line Basics
- Basic Commands: Navigating the file system (
cd
,ls
,pwd
), file operations (cp
,mv
,rm
,touch
), viewing and editing files (cat
,nano
,vi
). - File System Structure: Understanding the Linux file system hierarchy.
- Permissions and Ownership: Managing file permissions and ownership (
chmod
,chown
).
3. System Administration
- User and Group Management: Adding/removing users, managing groups (
useradd
,usermod
,groupadd
). - Package Management: Installing, updating, and removing software using package managers like
apt
,yum
, ordnf
. - System Monitoring and Processes: Monitoring system resources (
top
,htop
), managing processes (ps
,kill
,jobs
,bg
,fg
). - System Services and Daemons: Managing services with
systemd
(systemctl start
,stop
,enable
,disable
). - System Logs: Understanding and monitoring system logs (
/var/log
,journalctl
).
4. Shell Scripting
- Basics of Shell Scripting: Writing simple scripts, variables, control structures (if-else, loops).
- Advanced Scripting: Functions, arguments, script debugging.
5. Networking
- Basic Networking Commands:
ifconfig
,ping
,ssh
,scp
,netstat
. - Firewall Management: Basics of
iptables
and firewalld. - Network File System (NFS) and SSH Filesystem (SSHFS): Setting up file sharing and remote file systems.
6. Advanced Topics
- Disk Management: Partitioning, file systems creation, and mounting (
fdisk
,mkfs
,mount
). - Backup and Recovery: Tools and strategies for data backup and recovery.
- Virtualization: Introduction to virtualization technologies like KVM, VirtualBox.
- Containerization: Basics of Docker and container management.
- Security: Basic security practices, secure shell (SSH) setup, basic firewall setup.
7. Learning Resources
- Online Tutorials and Courses: Websites like Linux Academy, Coursera, and edX offer courses ranging from beginner to advanced levels.
- Books: “The Linux Command Line” by William Shotts, “How Linux Works” by Brian Ward.
- Community and Documentation: Engaging with the Linux community through forums like Stack Overflow, Reddit, and reading official documentation of Linux distributions.
This outline should help you systematically approach learning Linux, from understanding its basics to mastering advanced system administration tasks. Remember, the best way to learn is by doing, so try to practice each topic by setting up your own Linux environment to experiment in.
開發心得
要開發一個專案的時候,都先用最簡單最熟悉的技術。這樣一來專案早點成形,也比較有成就感。
時間多的話,可以慢慢研想要使用的技術。
Understanding JavaScript Closures: A Simple Explanation
In JavaScript, a closure is a feature where an inner function has access to variables from an outer function even after the outer function has finished executing. This happens because the inner function ‘remembers’ the environment in which it was created.
Here’s a simple way to understand it:
- Outer Function: You have an outer function that defines some variables.
- Inner Function: Inside this outer function, you create an inner function. This inner function can use the variables defined in the outer function.
- Closure: Even after the outer function has finished executing and its scope is gone, the inner function still has access to those variables. This persistent access to the variables of the outer function is what we call a closure.
It’s like having a backpack. When you leave your house (the outer function), you take things (variables) with you in your backpack. Throughout the day (even after you’ve left your house), you can still use everything you put in your backpack. That backpack and its contents are your closure in the outside world.