Monorepo

Monorepo simply means putting all of your company’s code in a Git/Mercurial/Subversion repository. For many people who haven’t heard of this concept, it’s a myth. Shouldn’t Git repositories be one per project? For many companies that use Monorepo, their Git repository contains not only their own code, but also many dependencies. Basically, by dragging monorepo down with Git and running./scripts/install, you can directly compile all projects in the repository with Buck/Bazel (which is installed locally in the installation script) and commit changes (the installation script configures the code commit environment, If you use Phabricator, Gerrit doesn’t.)

npm

Package manager under Nodejs

shell

The operating systems we use now (Windows, Mac OS, Android, iOS, etc.) are simple, intuitive and easy to use. They are very suitable for both professional users (programmers, network management, etc.) and ordinary users (housewives, the elderly, etc.). The popularity of computers depends on graphical interfaces.

However, in the early days of the computer, there was no graphical interface. We could only control the computer through hundreds of commands, not to mention remembering these commands was very difficult. It was boring to face the “black screen” without any color every day. Computers at this time were far from cool and popular. Only professionals could use them.

For a graphical interface, a user clicks an icon to launch a program. On the command line, the user starts a program by typing the name of the program (which can be viewed as a command). The basic process is similar in both cases, in that you need to find where your programs are installed on your hard disk and load them into memory to run. In other words, the graphical interface and the command line are all about the same thing: giving the user control over the computer. However, only the operating system Kernel can control the computer hardware (CPU, memory, display, etc.), and the graphical interface and command line are just a bridge between the user and the Kernel.

Due to security, complexity, tedious and other reasons, users can not directly contact the kernel (and it is not necessary), need to develop another program, let users directly use this program; The purpose of this program is to take the user’s actions (clicking on an icon, typing a command), do some simple processing, and then pass them to the kernel. This creates an additional layer of “agents” between the user and the kernel that both simplifies user operations and protects the kernel.

The user interface and the command line are this additional development, this layer of “agents.” Under Linux, this command line program is called a Shell.

yarn

Yarn is a package manager for your code. It allows you to use and share code (such as JavaScript) from developers around the world. Yarn can do this quickly, safely, and reliably, so you have nothing to worry about.

Yarn allows you to use other developers’ solutions to different problems to make your development process easier. If you encounter problems during use, you can report them or contribute solutions. Once the problem is fixed, Yarn updates to keep it in sync.

Code is shared through packages, or modules. A package contains all the code that needs to be shared, along with a file that describes the package information, called package.json.

lerna

Lerna is a workflow tool optimized for managing multi-package repositories with Git and NPM for JavaScript projects with multiple packages

git submodule

The Git Submodule allows one Git repository to act as a subdirectory of another Git repository while keeping the parent and subprojects independent of each other.

webpack alias

Directory alias Alias

webpack symlink

Soft links in webpack

The script tag imports resources

Script elements can point to external script files via the SRC attribute.