WeChat has now opened search within mini-programs . Developers can configure whether their mini-program pages are allowed to be indexed by WeChat through sitemap.json configuration or by managing the backend page inclusion switch. When developers allow WeChat indexing, WeChat will index the page content of the Mini Program through crawlers. When a user's search term triggers the index, the Mini Program's page may be displayed in the search results. When a crawler accesses a page in a mini program, it carries a specific user-agent: mpcrawler and a scenario value: 1129. It should be noted that if the page data discovered by the mini program crawler is inconsistent with the presentation of the real user, the page will not be included in the index. Sitemap Configuration The sitemap.json file in the root directory of the Mini Program is used to configure whether the Mini Program and its pages are allowed to be indexed by WeChat. The file content is a JSON object. If there is no sitemap.json, all pages are allowed to be indexed by default; sitemap.json has the following properties: Configuration items
rulesThe rules configuration item specifies the index rules. Each rule is a JSON object with the following properties:
matching value description
Configuration ExampleExample 1 { "rules":[{ "action": "allow", "page": "path/to/page", "params": ["a", "b"], "matching": "exact" }, { "action": "disallow", "page": "path/to/page" }]}
Example 2 { "rules":[{ "action": "allow", "page": "path/to/page", "params": ["a", "b"], "matching": "inclusive" }, { "action": "disallow", "page": "path/to/page" }]}
Example 3 { "rules":[{ "action": "allow", "page": "path/to/page", "params": ["a", "b"], "matching": "exclusive" }, { "action": "disallow", "page": "path/to/page" }]}
Example 4 { "rules":[{ "action": "allow", "page": "path/to/page", "params": ["a", "b"], "matching": "partial" }, { "action": "disallow", "page": "path/to/page" }]}
Note: If there is no sitemap.json, all pages can be indexed by default Note: {"action": "allow", "page": "*"} is the default rule with the lowest priority. All pages without "disallow" are indexed by default. |
<<: Community operation: How can community fission activities achieve high conversion rates?
>>: The 4 user quadrants of product promotion!
In the age of universal iodine supplementation, p...
In the news broadcast, we often hear such reports...
On the day JWT was merged with digital marketing ...
Recently, Jimifeng Network Customer Service has o...
Mobile phones are not only our communication tool...
Since its release, Model 3 has launched minor mod...
This year, our domestic game "Black Myth: Wu...
Clearing words, locking rankings , removing from ...
Modern people work, study and play games every da...
Good method "Beautiful Greater China" ta...
Recently, the topic #Gongcai is dried lettuce# ha...
What is the first thing that comes to your mind w...
As competition among video websites becomes incre...
How can we achieve twice the result with half the...
1. Event Planning Overview There are three keys t...