Funkcje XMLtoGraphQL

This commit is contained in:
2025-12-04 14:58:52 +01:00
parent c178a0e695
commit 69452672d4
4 changed files with 471 additions and 0 deletions

16
XMLtoGraphQL/readme.md Normal file
View File

@@ -0,0 +1,16 @@
# XMLtoGraphQL #
Function and xslt skeleton to turn XML products data to same as you would get from graphQL api
## Warning ##
Not every single piece of data is being handled by that function.
## Usage ##
With JS code you only need to put functions in script.js inside your code and then use idmGetGraphQLData to get graphQL'like data
```
const data = await idmGetGraphQLData("/pl/menu/perfumy/perfumy-meskie-944.html");
console.log(data);
```
With XSLT you will get script tag with JSON data inside. You just need to read that in your function
Created by • **[IdoMods](https://idomods.pl/)** • 2025