From 00815e68bcaa457460afddbd00edd9e3a61e9c40 Mon Sep 17 00:00:00 2001 From: Carl-Erik Kopseng Date: Tue, 11 May 2021 14:16:24 +0200 Subject: [PATCH] Point to Sinon 9 for legacy support --- COMPATIBILITY.md | 9 ++++++--- docs/release-source/release.md | 20 +++++--------------- 2 files changed, 11 insertions(+), 18 deletions(-) diff --git a/COMPATIBILITY.md b/COMPATIBILITY.md index c677491a6..f064fb741 100644 --- a/COMPATIBILITY.md +++ b/COMPATIBILITY.md @@ -4,13 +4,14 @@ This file is the canonical resource for compatibility goals for the libraries th ## ES2017 -The source is as [ES2017][es2017] and requires no transpiler or polyfills in supporting runtimes. +Sinon has historically been written as [ES5][es5], but starting from Sinon 10 we made the breaking change to allow more modern ECMAScript versions, starting with ECMAScript [2017][es2017]. +The source version is [ES2017][es2017] and requires no transpiler or polyfills in supporting runtimes. -For legacy runtimes, a transpiler can be used by dependent projects. +For legacy runtimes, a transpiler can be used by dependent projects., but use of newer APIs might break. If you need to support older browsers, have a look at Sinon 9. ## Runtimes -Sinon.JS aims at supporting the following runtimes: +Sinon.JS aims at supporting the following runtimes (from our shared [eslint-config][shared-config]). @@ -34,4 +35,6 @@ To see what that means in practice, you can use https://browserslist.dev Sauce Test Status

+[es5]: http://www.ecma-international.org/ecma-262/5.1/ [es2017]: https://262.ecma-international.org/8.0/ +[shared-config]: https://github.com/sinonjs/eslint-config diff --git a/docs/release-source/release.md b/docs/release-source/release.md index 320324428..e1de08b5b 100644 --- a/docs/release-source/release.md +++ b/docs/release-source/release.md @@ -25,24 +25,14 @@ This page contains the entire Sinon.JS API documentation along with brief introd {% include docs/migration-guides.md %} -## Compatibility - -The most up-to-date reference on which runtimes and browsers we support can be found by looking at our shared [eslint-config][shared-config]. - -### ECMAScript versions - -Sinon has historically been written as [ES5][es5], but starting from Sinon 10 we made the breaking change to use more modern ECMAScript versions, starting with ECMAScript [2017][es2017]. `{{page.release_id}}` requires no transpiler or polyfills to run in the runtimes mentioned below. - -### Supported runtimes +## Compatibility and supported runtimes As of Sinon 10 we stopped maintaining compatibility with legacy browsers. Instead, we focus on compatibility with evergreen browsers, [Node.js LTS versions](https://github.com/nodejs/Release) and recent Safari versions. +The most up-to-date reference on which runtimes and browsers we support can be found by looking at our [compatibility docs][compat-doc]. -There should not be any issues with using Sinon `{{page.release_id}}` in newer versions of the same runtimes. - -If you need to support old runtimes you can try one of the older Sinon versions. +If you need to support old runtimes you can try [Sinon 9][compat-doc-v9]. {% include docs/contribute.md %} -[es5]: http://www.ecma-international.org/ecma-262/5.1/ -[es2017]: http://www.ecma-international.org/ecma-262/8.0/ -[shared-config]: https://github.com/sinonjs/eslint-config +[compat-doc]: https://github.com/sinonjs/sinon/COMPATIBILITY.md +[compat-doc-v9]: https://github.com/sinonjs/sinon/blob/v9.2.4/COMPATIBILITY.md