0

currently I am using ResizableRect imported from this module mockingbot/react-resizable-rotatable-draggable. But it is unable to resize or drag the ResizableRect on the mobile browser and touching event is not available.

Then, I found this module rinose/react-resizable-rotatable-draggable, which has the touching event. However, there is no clear instruction on how to install the rinose's module as the content in README.md in rinose's module is exactly the same as that in mockingbot's module.

May I know how to import rinose's module into my project without using npm? Thanks!

UPDATE

I tried 'npm install git+https://github.com/rinose/react-resizable-rotatable-draggable.git' suggested by Antoine Raoul Iscaros but it still doesn't work. It stated that 'rollup-plugin-babel' module is not found though I had installed the module(which is already deprecated). Below are the error logs

 react-resizable-rotatable-draggable-touch@0.3.0-dev.0 prepack C:\Users\Forge-15\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-1a6e54a2
> npm run build


> react-resizable-rotatable-draggable-touch@0.3.0-dev.0 build C:\Users\Forge-15\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-1a6e54a2
> rollup -c

[!] Error: Cannot find module 'rollup-plugin-babel'
Require stack:
- C:\Users\Forge-15\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-1a6e54a2\rollup.config.js
- C:\Users\Forge-15\AppData\Roaming\npm\node_modules\rollup\dist\shared\loadConfigFile.js     
- C:\Users\Forge-15\AppData\Roaming\npm\node_modules\rollup\dist\bin\rollup
Error: Cannot find module 'rollup-plugin-babel'
Require stack:
- C:\Users\Forge-15\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-1a6e54a2\rollup.config.js
- C:\Users\Forge-15\AppData\Roaming\npm\node_modules\rollup\dist\shared\loadConfigFile.js     
- C:\Users\Forge-15\AppData\Roaming\npm\node_modules\rollup\dist\bin\rollup
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:966:15)
    at Function.Module._load (internal/modules/cjs/loader.js:842:27)
    at Module.require (internal/modules/cjs/loader.js:1026:19)
    at require (internal/modules/cjs/helpers.js:72:18)
    at Object.<anonymous> (C:\Users\Forge-15\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-1a6e54a2\rollup.config.js:5:13)
    at Module._compile (internal/modules/cjs/loader.js:1138:30)
    at Object.require.extensions.<computed> [as .js] (C:\Users\Forge-15\AppData\Roaming\npm\node_modules\rollup\dist\shared\loadConfigFile.js:508:20)
    at Module.load (internal/modules/cjs/loader.js:986:32)
    at Function.Module._load (internal/modules/cjs/loader.js:879:14)
    at Module.require (internal/modules/cjs/loader.js:1026:19)

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! react-resizable-rotatable-draggable-touch@0.3.0-dev.0 build: `rollup -c`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the react-resizable-rotatable-draggable-touch@0.3.0-dev.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Forge-15\AppData\Roaming\npm-cache\_logs\2020-08-28T04_25_05_798Z-debug.log
npm ERR! premature close

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Forge-15\AppData\Roaming\npm-cache\_logs\2020-08-28T04_25_05_840Z-debug.log
LY Hooi
  • 165
  • 1
  • 9
  • Does this answer your question? [How to install an npm package from GitHub directly?](https://stackoverflow.com/questions/17509669/how-to-install-an-npm-package-from-github-directly) – Antoine Eskaros Aug 27 '20 at 16:44
  • Hi, it still does not work. I have updated my post with the error logs. Please help me. Thanks. – LY Hooi Aug 28 '20 at 04:36

1 Answers1

1

you can install directly from git using

npm install git+https://github.com/rinose/react-resizable-rotatable-draggable.git

Question is already answered here How to install an npm package from GitHub directly?

Antoine Eskaros
  • 836
  • 5
  • 22
  • Hi, it still does not work. I have updated my post with the error logs. Please help me. Thanks. – LY Hooi Aug 28 '20 at 04:36