contentful / contentful.js

JavaScript library for Contentful's Delivery API (node & browser)
https://contentful.github.io/contentful.js
MIT License
1.18k stars 197 forks source link

Documentation on ordering is broken. Unable to order. #2015

Open seenickcode opened 11 months ago

seenickcode commented 11 months ago

Expected Behavior

I am able to follow the following code snippet cited here in the documentation:

client
  .getEntries({
    skip: 100,
    limit: 200,
    order: 'sys.createdAt',
  })
  .then(function (entries) {
    console.log(entries.items.length); // 200
  });

Actual Behavior

Screenshot 2023-09-18 at 7 21 46 AM

Steps to Reproduce

Provided in 'expected behavior' above.

Context

I am unable to query by a field match AND order.

Environment

➜ node -v
v19.7.0

➜ npm -v
9.6.5

➜ uname -a
22.6.0 Darwin Kernel Version 22.6.0: Wed Jul  5 22:22:05 PDT 2023; root:xnu-8796.141.3~6/RELEASE_ARM64_T6000 arm64

Package Version: "contentful": "^10.5.2",

Which API are you using?: Delivery

PatrWade commented 1 month ago

fyi.,this can be closed and reference to this thread: https://github.com/contentful/contentful.js/issues/2017