From dff88b0769dfc1d762df07f2577a2d63e7a2054f Mon Sep 17 00:00:00 2001 From: Carlo Beltrame Date: Wed, 29 Jun 2022 09:44:20 +0200 Subject: [PATCH] Webpack apparently prefers relative paths in the browser field This is an attempt to fix the size-limit CI --- packages/image/package.json | 8 ++++---- packages/pdfkit/package.json | 4 ++-- packages/png-js/package.json | 4 ++-- packages/renderer/package.json | 4 ++-- packages/textkit/package.json | 4 ++-- packages/yoga/package.json | 4 ++-- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/image/package.json b/packages/image/package.json index c1baa6c04..136faa0b8 100644 --- a/packages/image/package.json +++ b/packages/image/package.json @@ -5,11 +5,11 @@ "description": "Parses the images in png or jpeg format for react-pdf document", "author": "Diego Muracciole ", "homepage": "https://github.com/diegomura/react-pdf#readme", - "main": "lib/index.cjs.js", - "module": "lib/index.es.js", + "main": "./lib/index.cjs.js", + "module": "./lib/index.es.js", "browser": { - "lib/index.cjs.js": "lib/index.browser.cjs.js", - "lib/index.es.js": "lib/index.browser.es.js" + "./lib/index.cjs.js": "./lib/index.browser.cjs.js", + "./lib/index.es.js": "./lib/index.browser.es.js" }, "repository": { "type": "git", diff --git a/packages/pdfkit/package.json b/packages/pdfkit/package.json index daef73a56..6491b0275 100644 --- a/packages/pdfkit/package.json +++ b/packages/pdfkit/package.json @@ -2,8 +2,8 @@ "name": "@react-pdf/pdfkit", "version": "2.4.0", "description": "A PDF generation library for Node.js", - "main": "lib/pdfkit.cjs.js", - "module": "lib/pdfkit.es.js", + "main": "./lib/pdfkit.cjs.js", + "module": "./lib/pdfkit.es.js", "repository": { "type": "git", "url": "https://github.com/diegomura/react-pdf.git", diff --git a/packages/png-js/package.json b/packages/png-js/package.json index bbbf77491..8e7fb7445 100644 --- a/packages/png-js/package.json +++ b/packages/png-js/package.json @@ -2,8 +2,8 @@ "name": "@react-pdf/png-js", "description": "A PNG decoder in JS", "version": "2.1.0", - "main": "lib/png-js.cjs.js", - "module": "lib/png-js.es.js", + "main": "./lib/png-js.cjs.js", + "module": "./lib/png-js.es.js", "browser": { "./lib/png-js.es.js": "./lib/png-js.browser.es.js", "./lib/png-js.cjs.js": "./lib/png-js.browser.cjs.js" diff --git a/packages/renderer/package.json b/packages/renderer/package.json index b7afab90e..e69627a8e 100644 --- a/packages/renderer/package.json +++ b/packages/renderer/package.json @@ -6,8 +6,8 @@ "types": "index.d.ts", "author": "Diego Muracciole ", "homepage": "https://github.com/diegomura/react-pdf#readme", - "main": "lib/react-pdf.cjs.js", - "module": "lib/react-pdf.es.js", + "main": "./lib/react-pdf.cjs.js", + "module": "./lib/react-pdf.es.js", "repository": { "type": "git", "url": "https://github.com/diegomura/react-pdf.git", diff --git a/packages/textkit/package.json b/packages/textkit/package.json index 0b4f94162..29717c002 100644 --- a/packages/textkit/package.json +++ b/packages/textkit/package.json @@ -3,8 +3,8 @@ "license": "MIT", "version": "4.0.0", "description": "An advanced text layout framework", - "main": "lib/textkit.cjs.js", - "module": "lib/textkit.es.js", + "main": "./lib/textkit.cjs.js", + "module": "./lib/textkit.es.js", "browser": { "./lib/textkit.es.js": "./lib/textkit.browser.es.js", "./lib/textkit.cjs.js": "./lib/textkit.browser.cjs.js" diff --git a/packages/yoga/package.json b/packages/yoga/package.json index ab760efb2..61cff9636 100644 --- a/packages/yoga/package.json +++ b/packages/yoga/package.json @@ -5,8 +5,8 @@ "license": "MIT", "author": "Diego Muracciole ", "homepage": "https://github.com/diegomura/react-pdf#readme", - "main": "src/dist/entry-browser.js", - "module": "src/dist/entry-browser.es.js", + "main": "./src/dist/entry-browser.js", + "module": "./src/dist/entry-browser.es.js", "types": "index.d.ts", "repository": { "type": "git",