@speclynx/apidom-parser-adapter-json-schema-json-2020-12 2.2.3 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,12 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [2.3.0](https://github.com/speclynx/apidom/compare/v2.2.3...v2.3.0) (2026-01-27)
7
+
8
+ ### Features
9
+
10
+ - support strict parsing mode through out the packages ([#46](https://github.com/speclynx/apidom/issues/46)) ([e6b47d9](https://github.com/speclynx/apidom/commit/e6b47d9cfdede7103cada67362b316fd8e5b787f)), closes [#23](https://github.com/speclynx/apidom/issues/23)
11
+
6
12
  ## [2.2.3](https://github.com/speclynx/apidom/compare/v2.2.2...v2.2.3) (2026-01-26)
7
13
 
8
14
  **Note:** Version bump only for package @speclynx/apidom-parser-adapter-json-schema-json-2020-12
@@ -18173,7 +18173,7 @@ __webpack_require__.r(__webpack_exports__);
18173
18173
  /* harmony export */ syntacticAnalysis: () => (/* reexport safe */ _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_5__["default"])
18174
18174
  /* harmony export */ });
18175
18175
  /* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5156);
18176
- /* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6126);
18176
+ /* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(746);
18177
18177
  /* harmony import */ var _native_index_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8600);
18178
18178
  /* harmony import */ var _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4885);
18179
18179
  /* harmony import */ var _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9305);
@@ -18218,10 +18218,6 @@ const detect = async (source, {
18218
18218
  * @public
18219
18219
  */
18220
18220
 
18221
- /**
18222
- * @public
18223
- */
18224
-
18225
18221
  /**
18226
18222
  * @public
18227
18223
  */
@@ -26115,6 +26111,9 @@ __webpack_require__.r(__webpack_exports__);
26115
26111
  * @public
26116
26112
  */
26117
26113
  const detect = async source => {
26114
+ if (source.trim().length === 0) {
26115
+ return false;
26116
+ }
26118
26117
  try {
26119
26118
  JSON.parse(source);
26120
26119
  return true;
@@ -26127,9 +26126,12 @@ const detect = async source => {
26127
26126
  * @public
26128
26127
  */
26129
26128
  const parse = async source => {
26129
+ const parseResult = new _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__["default"]();
26130
+ if (source.trim().length === 0) {
26131
+ return parseResult;
26132
+ }
26130
26133
  const pojo = JSON.parse(source);
26131
26134
  const element = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__.refract)(pojo);
26132
- const parseResult = new _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__["default"]();
26133
26135
  element.classes.push('result');
26134
26136
  parseResult.push(element);
26135
26137
  return parseResult;
@@ -29230,7 +29232,11 @@ const detectionRegExp = /"\$schema"\s*:\s*"https:\/\/json-schema\.org\/draft\/(?
29230
29232
  /**
29231
29233
  * @public
29232
29234
  */
29233
- const detect = async source => detectionRegExp.test(source) && (await (0,_speclynx_apidom_parser_adapter_json__WEBPACK_IMPORTED_MODULE_4__.detect)(source));
29235
+ const detect = async (source, options = {}) => detectionRegExp.test(source) && (await (0,_speclynx_apidom_parser_adapter_json__WEBPACK_IMPORTED_MODULE_4__.detect)(source, options));
29236
+
29237
+ /**
29238
+ * @public
29239
+ */
29234
29240
 
29235
29241
  /**
29236
29242
  * @public