A, support,

  • List of ecological adaptations: ecology.chinauos.com/
  • Electron ARM Support: www.electronjs.org/zh/

Two, environment configuration

  1. Open Developer mode (Control Center => General => Developer Mode)
  2. Configure git permission and run permission
  3. The system configuration

Changing the number of Max User processes:

Vim/etc/security/limits hardnproc softnproc conf * 65536 * 65536Copy the code

Resize vm.max_map_count: the max_map_count file contains limits on the number of Vmas (virtual memory areas) that a process can have

#A temporary change
sysctl -w vm.max_map_count=262144

#A permanent change
vim /etc/sysctl.conf
vm.max_map_count=262144
sysctl -p
Copy the code

Adjust the file monitor handle

vi /etc/sysctl.conf
fs.inotify.max_user_watches=524288
Copy the code

⚠ Note: Run sysctl -p for the configuration to take effect.

  1. The node/NPM configuration

Install to /usr/local/ and soft chain. After this configuration, the node command can be used by both root and other users.

sudo ln -s /usr/local/bin/node   /bin/node
sudo ln -s /usr/local/bin/npm    /bin/npm
Copy the code

Third, compatible

node-sass => sass(dart-sass);

  • Version information
"sass": "^ 1.26.5"."sass-loader": "^ 7.1.0"
Copy the code
  • Sass \ webpack configuration
{
    test: /\.scss$/,
    use: [
        'vue-style-loader'.'css-loader',
            {
                loader: 'sass-loader'.options: {
                    implementation: require('sass'}}]}Copy the code
  • Note File paths are case sensitive

Four, logical problems:

  • The renderer cannot call the main process function directly (there are hidden calls);
  • Dynamic link library constants and non-dynamic link library functions are stripped;
  • Do not use dynamic link libraries for renderers.
  • Node-sass => sass style compatible, eg: /deep/ => ::v-deep, nth-child…

Five, the other

Configuration of yarn

Obtain the installation source:

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
Copy the code

Installation:

sudo apt-get install yarn
yarn --version
Copy the code

Install curl

curl --version
sudo apt install curl
## To uninstall
## sudo apt remove curl
curl --version
#Viewing the Terminal IP Address
curl ip.gs
Copy the code