mattmilburn / strapi-plugin-preview-button

A plugin for Strapi CMS that adds a preview button and live view button to the content manager edit view.
MIT License
100 stars 35 forks source link

npm install error (peer dependency conflict) #56

Closed samzlab closed 1 year ago

samzlab commented 1 year ago

npm install error

image

versions

Strapi: 4.4.0 node: v16.17.0 npm: 8.15.0

reproduction

workaround

Yes, using the --force flag on install

mattmilburn commented 1 year ago

Hi @samzlab I'm unable to reproduce this issue after meeting all of the specs you provided. Can you provide more details of your package.json? I feel like there is a conflicting dependency that I don't know about.

samzlab commented 1 year ago
{
  "name": "strapi-test",
  "private": true,
  "version": "0.1.0",
  "description": "A Strapi application",
  "scripts": {
    "develop": "strapi develop",
    "start": "strapi start",
    "build": "strapi build",
    "strapi": "strapi"
  },
  "dependencies": {
    "@strapi/plugin-documentation": "^4.4.0",
    "@strapi/plugin-i18n": "4.4.0",
    "@strapi/plugin-users-permissions": "4.4.0",
    "@strapi/strapi": "4.4.0",
    "better-sqlite3": "7.4.6",
    "strapi-plugin-preview-button": "^1.0.0",
    "strapi-plugin-publisher": "^1.1.3"
  },
  "author": {
    "name": "A Strapi developer"
  },
  "strapi": {
    "uuid": "acb7cc1a-405b-4f27-aa3f-a717ad3e3b97"
  },
  "engines": {
    "node": ">=14.19.1 <=18.x.x",
    "npm": ">=6.0.0"
  },
  "license": "MIT"
}

The interesting part is that now, if i make a fresh project there is no conflict.

But can still reproduce the error with npm ci. Should i attach the package-lock.json aswell?

samzlab commented 1 year ago

Well, i just removed the publisher plugin and now it's stops conflicting (i realized late that the error message mentioned that plugin too).

So nvm, looks like it's not caused by the preview-button :) Sorry for wasting your time!

mattmilburn commented 1 year ago

@samzlab Glad you were able to resolve your issue! 🎉