Skip to content

docs(arcgis-rest-portal): fix incorrect documentation for searchGroupContent #1208

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Apr 7, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions packages/arcgis-rest-developer-credentials/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# @esri/arcgis-rest-developer-credentials [2.1.0](https://github.com/Esri/arcgis-rest-js/compare/@esri/[email protected]...@esri/[email protected]) (2025-02-26)


### Features

* **arcgis-rest-developer-credentials:** add invalidateApiKey, fix generate API key bug ([b1458a2](https://github.com/Esri/arcgis-rest-js/commit/b1458a2b91c4c4b44254600e54d72a040b8bcf4e))

# @esri/arcgis-rest-developer-credentials [2.0.0](https://github.com/Esri/arcgis-rest-js/compare/@esri/[email protected]...@esri/[email protected]) (2025-02-20)


Expand Down
2 changes: 1 addition & 1 deletion packages/arcgis-rest-developer-credentials/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@esri/arcgis-rest-developer-credentials",
"version": "2.0.0",
"version": "2.1.0",
"description": "Developer Credentials for @esri/arcgis-rest-js",
"license": "Apache-2.0",
"keywords": [
Expand Down
16 changes: 12 additions & 4 deletions packages/arcgis-rest-portal/src/groups/search.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,20 @@ export function searchGroups(
* ```js
* import { searchGroupContent } from "@esri/arcgis-rest-portal";
*
* searchGroupContent('water')
* .then(response) // response.total => 355
* searchGroupContent({
* q: 'water',
* groupId: 'abc123'
* })
* .then(response => {
* console.log(response.total); // response.total => 355
* });
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section looks good. I think you can remove the // response.total => 355 line since this is just a fake example the number 355 does not really make sense.

* ```
*
* @param options - RequestOptions object amended with search parameters.
* @returns A Promise that will resolve with the data from the response.
* @param options - An object containing search parameters.
* @param options.q - The search query (required).
* @param options.groupId - The ID of the group to search within (required).
* @param options.params - Additional search parameters (optional).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not think you need to add these lines ... the automatic doc generator will link to ISearchGroupContentOptions properly as it does currently on https://developers.arcgis.com/arcgis-rest-js/api-reference/arcgis-rest-portal/searchGroupContent/ :
image

* @returns A Promise that resolves to the search result containing items within the specified group.
*/
export function searchGroupContent(
options: ISearchGroupContentOptions
Expand Down