Sometimes, switching the source of npm packages in a project is necessary due to network or security issues. The general practice is to switch the source in npmrc, but after switching and installing packages, you will find that the install still goes through the old source, primarily when a lock file has already been generated.

Here, we analyze the issue of the registry not working.

Version Information

For verification, I am using the following versions:

  • npm v9.5.1

  • node v18.16.1

Read more »

Issue

In projects using redux-logger, redux-logger still exists after packaging in Webpack production mode.

Theoretically, the logger should only be used in the development environment, so it should be removed after packaging. Therefore, with this question in mind, let’s analyze the problem.

Code Details

Read more »

Recently, I used Monaco editor to implement an SQL editor. To improve the user experience, code auto-completion was necessary. After some research, I found a solution, so I’m marking it down here.

Built-in Autocompletion?

YES, Monaco supports some built-in languages by default, such as JavaScript, TypeScript, CSS, JSON, and HTML. You can achieve code autocompletion for languages with built-in support simply by setting the editor language to JavaScript`.

However, for languages like SQL that do not have built-in support, setting the editor language to SQL only enables syntax highlighting.

Read more »

Recently, because of Claude Sonnet and Cursor, I started contacting Claude. After using it for a while, I found that Claude is quite good; at least, I feel it’s on par with ChatGPT at the moment.

Here I’ll mark down some usage tips.

Requirements

  • VPN
    • This is similar to ChatGPT; both require solving network issues.
    • The list of countries supported by Claude can be found here.
    • If the proxy network is not good, account suspension is likely later.
    • You can refer to my proxy solution for those who haven’t solved the VPN issue.
  • Foreign phone number
    • Google Voice is not supported; using a GV number to receive an SMS verification code will result in an immediate error.
    • Getting a foreign SIM card, such as Giffgaff, is impossible if you don’t have one.
    • Using SMS verification code platforms recommended online may result in a higher chance of not receiving the verification code.

Register

Read more »

Technical reviews are required for functions that take more than three days to develop, so drawing skills are essential.

My company encourages the use of draw.io for drawing, and the more I use it, the more amazing I find this tool. So, regarding its usage, here’s a basic explanation for marking.

Platform

Draw.io is free and cross-platform.

  • Web

  • App

    It uses Electron, so it supports various OS.

Open Source?

Read more »
0%