Skip to content

fix: doc type fixes #53

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 2 commits into from
Sep 27, 2024
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
16 changes: 8 additions & 8 deletions src/lib/asset-query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().version(1).find();
*/
version(version: number): AssetQuery {
Expand All @@ -33,7 +33,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().includeDimension().find();
*/
includeDimension(): AssetQuery {
Expand All @@ -50,7 +50,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().includeBranch().find();
*/
includeBranch(): AssetQuery {
Expand All @@ -67,7 +67,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().includeMetadata().fetch();
*/
includeMetadata(): AssetQuery {
Expand All @@ -84,7 +84,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().relativeUrls().find();
*/
relativeUrls(): AssetQuery {
Expand All @@ -101,7 +101,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().includeFallback().find();
*/
includeFallback(): AssetQuery {
Expand All @@ -118,7 +118,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().locale('en-us').find();
*/
locale(locale: string): AssetQuery {
Expand All @@ -134,7 +134,7 @@ export class AssetQuery extends BaseQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().query().where('fieldUid', queryOperators, 'value').find();
*/
query() {
Expand Down
16 changes: 8 additions & 8 deletions src/lib/asset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').includeFallback().fetch();
*/
includeFallback(): Asset {
Expand All @@ -35,7 +35,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').includeMetadata().fetch();
*/
includeMetadata(): Asset {
Expand All @@ -52,7 +52,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').includeDimension().fetch();
*/
includeDimension(): Asset {
Expand All @@ -69,7 +69,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').includeBranch().fetch();
*/
includeBranch(): Asset {
Expand All @@ -86,7 +86,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').relativeUrls().fetch();
*/
relativeUrls(): Asset {
Expand All @@ -103,7 +103,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').version(1).fetch();
*/
version(version: number): Asset {
Expand All @@ -120,7 +120,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').locale('en-us').fetch();
*/
locale(locale: string): Asset {
Expand All @@ -137,7 +137,7 @@ export class Asset {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset('asset_uid').fetch();
*/
async fetch<T>(): Promise<T> {
Expand Down
22 changes: 11 additions & 11 deletions src/lib/base-query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.includeCount().find()
* // OR
Expand All @@ -37,7 +37,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.orderByAscending("field_uid").find()
* // OR
Expand All @@ -58,7 +58,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.orderByDescending("field_uid").find()
* // OR
Expand All @@ -79,7 +79,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.limit("limit_value").find()
* // OR
Expand All @@ -100,7 +100,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.skip("skip_value").find()
* // OR
Expand All @@ -123,7 +123,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.param("key", "value").find()
* // OR
Expand All @@ -144,7 +144,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.addParams({"key": "value"}).find()
* // OR
Expand All @@ -165,7 +165,7 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const query = stack.contentType("contentTypeUid").entry().query();
* const result = await query.removeParam("query_param_key").find()
* // OR
Expand All @@ -187,17 +187,17 @@ export class BaseQuery extends Pagination {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset().find();
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.contentType("contentType1Uid").entry().query().find();
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.asset(asset_uid).fetch();
*/

Expand Down
4 changes: 2 additions & 2 deletions src/lib/content-type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export class ContentType {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const entry = stack.contentType("contentTypeUid").entry("entryUid");
*/
entry(uid: string): Entry;
Expand All @@ -45,7 +45,7 @@ export class ContentType {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const result = await stack.contentType(asset_uid).fetch();
*/
async fetch<T>(): Promise<T> {
Expand Down
4 changes: 2 additions & 2 deletions src/lib/contentstack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ let version = '{{VERSION}}';
*
* @example
* import contentstack from '@contentstack/delivery-sdk'
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* @example
* import contentstack from '@contentstack/delivery-sdk'
* const stack = contentstack.Stack({
* const stack = contentstack.stack({
* apiKey: "apiKey",
* deliveryToken: "deliveryToken",
* environment: "environment",
Expand Down
4 changes: 2 additions & 2 deletions src/lib/contenttype-query.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class ContentTypeQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const contentTypeQuery = stack.contentType();
* const result = await contentTypeQuery.includeGlobalFieldSchema().find();
*/
Expand All @@ -35,7 +35,7 @@ export class ContentTypeQuery {
* @example
* import contentstack from '@contentstack/delivery-sdk'
*
* const stack = contentstack.Stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const stack = contentstack.stack({ apiKey: "apiKey", deliveryToken: "deliveryToken", environment: "environment" });
* const contentTypeQuery = stack.contentType();
* const result = await contentTypeQuery.find();
*/
Expand Down
Loading
Loading