From e4578a0c3d8c49e725ebf9be34692b5018872db0 Mon Sep 17 00:00:00 2001 From: Justin Poehnelt Date: Wed, 22 Dec 2021 09:56:47 -0700 Subject: [PATCH] docs: update place-fields docs --- docs/rules/place-fields.md | 10 ++++++++-- src/rules/place-fields.ts | 11 +++++++++-- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/docs/rules/place-fields.md b/docs/rules/place-fields.md index 8c52a08..62a4946 100644 --- a/docs/rules/place-fields.md +++ b/docs/rules/place-fields.md @@ -2,8 +2,14 @@ # place-fields -Use the `fields` option to limit the fields returned by the API and costs. Request to the Places API are billed by the fields that are returned. See [data-skus](https://developers.google.com/maps/documentation/places/web-service/usage-and-billing#data-skus) for more details. -> **Note**: This rule is not exhaustive and ignores `Autocomplete.setFields()`. +Use the `fields` option to limit the fields returned by the API and costs. Requests to the Places API are billed by the fields that are returned. See [Places Data SKUs](https://developers.google.com/maps/documentation/places/web-service/usage-and-billing#data-skus) for more details. + +More information about fields for specific API calls can be found at the following links: + +- [Place Details fields guidance](https://goo.gle/3H0TxxG) +- [Place Autocomplete fields guidance](https://goo.gle/3sp2XyS) + +> **Note**: This rule is not exhaustive. For example, it ignores `Autocomplete.setFields()`. 📋 This rule is enabled in `plugin:googlemaps/recommended`. diff --git a/src/rules/place-fields.ts b/src/rules/place-fields.ts index efeda88..d440223 100644 --- a/src/rules/place-fields.ts +++ b/src/rules/place-fields.ts @@ -20,8 +20,15 @@ import { createRule, camelCased } from "../utils/rules"; export const messageId = camelCased(__filename); -const description = `Use the \`fields\` option to limit the fields returned by the API and costs. Request to the Places API are billed by the fields that are returned. See [data-skus](https://developers.google.com/maps/documentation/places/web-service/usage-and-billing#data-skus) for more details. -> **Note**: This rule is not exhaustive and ignores \`Autocomplete.setFields()\`.`; +const description = `Use the \`fields\` option to limit the fields returned by the API and costs. Requests to the Places API are billed by the fields that are returned. See [Places Data SKUs](https://developers.google.com/maps/documentation/places/web-service/usage-and-billing#data-skus) for more details. + +More information about fields for specific API calls can be found at the following links: + +- [Place Details fields guidance](https://goo.gle/3H0TxxG) +- [Place Autocomplete fields guidance](https://goo.gle/3sp2XyS) + +> **Note**: This rule is not exhaustive. For example, it ignores \`Autocomplete.setFields()\`.`; + export default createRule({ name: __filename, meta: {