Recommended | variable named bad play? Take a look at how other programmers are named in

This article is Almost Human (public number: almosthuman2014) reprinted with permission, is prohibited reprint secondary
Almost Human reports


"variable names you get too bad," may be the programmers tucao hands with each other conventional type, in addition to not write comments, do not wrap (wrap?), unknown demand ......

1

Phil Karlton: computer science there are two problems: one is a cache miss, the other is named.

Well, well, now there is this magical site that allows us to solve this big problem, and to variable names based on Pinyin system to say goodbye.

2

Web site address: https://unbug.github.io/codelf/
GitHub link: https://github.com/unbug/codelf#codelf-for-vs-code

We made some attempts, such as typing Chinese "residual" in the search box below the search box will appear Suggestions, lists a number of the English translation. Suggestions below the piece "colorful" default is the first proposal included all the variables and function names in English translation.

3

Click Other suggestions translation, "colorful" the bottom will change. For example, click on the "error", change the search results are shown below.

4

You can also choose their favorite programming language, such as Python.

5

Look at changes in search results.

6

Move the mouse pointer over a color box, there will be "Search," "Repo", "Copy", "Codes" four options. Users can click on these options, use the corresponding function.

7

Click on "Search" is based on the current name search other related names. For example, click on the "residuals" after "Search" results are shown below.

8

Click on "Repo" is linked to the use of the named code repository is located.

9

Click "Copy" to copy the name.

Click on "Codes" can view the sample code uses named.

10

The sample code may need to select a different language.

11

According to the authors introduce internal Codelf principle is: first to take the proper way translation API Chinese translation, then search GitHub take variables. The site supports Chinese search directly in the search box and type Chinese, Codelf will provide a good search word and its synonyms, and then matched with the source code by searching Github, Bitbucket, Google Code, Codeplex, Sourceforge, open source projects on the Fedora Project these words variable and function names related. Of course, the direct input English also possible, Codelf will provide relevant name.

12

In addition, Codelf website can also manage your GitHub project, click on the icon in the top right of the left side of the site, log on GitHub account management user name Star and Repo.

13


Written in the last words

Welcome to Ali cloud intelligent data exchange group, where you can learn about AI experience the product, and fellow developers to more exchanges and discussions.

One: search nails into the digital exchange group: 23,116,044
II: nail into the two-dimensional code scanning exchange group:
test

Guess you like

Origin yq.aliyun.com/articles/704209
Recommended