You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
**Note:** Please do not crawl randomly, you can check the **robots.txt** protocol before crawling. The class name of the website may change, this is just to demonstrate how to use x-crawl.
@@ -788,6 +789,34 @@ myXCrawl
788
789
789
790
The larger the value of the priority attribute, the higher the priority in the current crawling queue.
790
791
792
+
### Print information
793
+
794
+
The crawled print information consists of start (displaying mode and total number), process (displaying number and how long to wait), and result (displaying success and failure information). There will be something like **1-page-2** in front of each piece of information. The first 1 represents the first crawler instance, the middle page represents the API type, and the following 2 represents the second page of the first crawler instance. Do this The purpose is to better distinguish which API the information comes from.
795
+
796
+
When you do not want to display the crawled information in the terminal, you can control the display or hiding through the options.
797
+
798
+
```js
799
+
importxCrawlfrom'x-crawl'
800
+
801
+
// Only hide the process, start and result display
802
+
constmyXCrawl=xCrawl({ log: { process:false } })
803
+
804
+
// Hide all information
805
+
constmyXCrawl=xCrawl({ log:false })
806
+
```
807
+
808
+
The log option accepts an object or boolean type:
809
+
810
+
- Boolean
811
+
812
+
- true: show all
813
+
- false: hide all
814
+
815
+
- object
816
+
- start: control the start information
817
+
- process: control of process information
818
+
- result: control of result information
819
+
791
820
### About Results
792
821
793
822
Each crawl target will generate a detail object, which will contain the following properties:
0 commit comments