Tag:Format

  • JS formats JSON strings and JSON objects

    Time:2021-6-23

    Formatting JSON objects const list= {name: ‘lisi’,age: 14,id: 1} JSON.stringify(list, null, “\t”) Format JSON string let list= “{name: ‘lisi’,age: 14,id: 1}” list = JSON.parse(list) JSON.stringify(list, null, “\t”) output { name: ‘lisi’, age: 14, id: 1 } JS formats JSON strings and JSON objects

  • Linux notes sharing 2: Linux system installation

    Time:2021-6-22

    1、 Virtual machine installation VMware VMware is a PC software, running it can simulate a new system. 2、 Virtual machine usage Don’t install with image, choose blank installation!!! In the hardware configuration with CD-ROM ISO can be 3、 System partition Partition is to use the partition editor to divide the disk into several logical parts. […]

  • Spark – 15 minute tutorial

    Time:2021-6-22

    By Andrea ialentiCompile VKSource: towards Data Science As I’ve written in almost all my articles about this tool, spark is as easy to use as SQL. But no matter how much time I spend writing code, I just can’t store the spark API permanently in my brain (some people will say that my memory is […]

  • C programming rookie exercises 100 questions (01-10)

    Time:2021-6-22

    [exercise 1] output “Hello, world!” Title:Output “Hello, world!” 1. AnalysisUse printf() to output “Hello, world!”. 2. Procedure: #include int main() { printf(“Hello, World!”); // Double quotation marks are required before and after strings in printf() return 0; } 3. Input and output: Hello, World! 4. Expand knowledge:Printf() is a function defined in the header file […]

  • Parameter verification of flash development skills

    Time:2021-6-21

    Parameter verification of flash development skills catalogue Parameter verification of flash development skills 1. Request parameter classification 2. Libraries used by the solution 3. For URL query parameters and general JSON format 4. For complex JSON format data I usually use in the development, or learn some flash development skills, need to have a solid […]

  • Basics of canvas

    Time:2021-6-21

    This article can be used as a basic reference of canvas. Basically covers all the canvas content, of course, does not include the use of canvas to deal with advanced applications. Line The basic problems are as follows: Draw a line The basic architecture is as follows ctx.beginPath(); // Start drawing lines, there are no […]

  • The use of Android native WebView

    Time:2021-6-21

    The use of Android native WebView Android WebView is a special view on Android platform, which is used to display web pages. This WebView class can be used to display an online web page, and of course, it can also be used to develop browsers.The internal implementation of WebView uses WebKit to display the content […]

  • The pleasure of one click formatting code – are you still configuring stylelint and eslint for each project

    Time:2021-6-20

    Author:JowayYoungWarehouse:Github、CodePenBlog:Official website、Nuggets、Do you think about it、ZhihuOfficial account:IQ front endSpecial statement: original is not easy, without authorization can not reprint or plagiarize, if you need to reprint can contact the author authorized preface Most front-end projects are configuredStylelint、Eslint、TslintandPrettierFour front-end code verification tools.Code verification toolhereinafter referred to asLintIn order to solve the problem that the code is […]

  • Laravel creates an exception handling response format suitable for API

    Time:2021-6-20

    After laravel catches the exception globally, it will convert the exception into the corresponding data format and return it to the user. If you want the specified data format to be appropriate, we just need to rewrite the handling method after exception capture. Exception handling process Illuminate\Foundation\Exception\HandlerThe render method in is used to convert an […]

  • Introduction to Java document annotation

    Time:2021-6-18

    notesComments play a role in code annotation and interpretation. If you look at the JDK source code, you will find that they have many comments, and comments are more than code. It can be seen that adding comments to code is very important. Writing comments can make it easier for others to understand your code. […]

  • Linux learning notes (lesson 3)

    Time:2021-6-17

    File directory management command—————————————————————————————–The touch command is used to create a blank file or set the time of the file. The syntax format is “touch [parameter] file name[[email protected] mnt]# ls[[email protected] mnt]# touch bing[[email protected] mnt]# lsbing#VIM Linux uses VIM to edit a nonexistent file. After modifying and saving, the file will be created automatically[[email protected] mnt]# vim […]

  • Collection of laravel

    Time:2021-6-16

    Laravel’s collection class actually has many very practical methods, which are very useful for us to optimize loops. Our goal is to:No more writingforeachCycle! 1、 Sum price sum      We’ll learnflatMap map sumAnd so on collect($arr)->pluck(‘order_products.*.price’)->flatten(1)->sum(); 2、 Format gate      Hope to deepenmapUnderstanding and understanding ofmapApplication scenarios of 3、 Calculate GitHub activity      After getting […]