nurpax / petmate

PETSCII editor with Electron/React/Redux
MIT License
178 stars 14 forks source link

Build error (Raspbian) - TypeScript error in ImportModal.tsx(235,21) #210

Open bferguson3 opened 3 years ago

bferguson3 commented 3 years ago
> petmate@0.8.4 build /home/pi/Projects/petmate
> react-scripts build "dist-linux"

Creating an optimized production build...
Failed to compile.

/home/pi/Projects/petmate/src/containers/ImportModal.tsx
TypeScript error in /home/pi/Projects/petmate/src/containers/ImportModal.tsx(235,21):
'charset' is specified more than once, so this usage will be overwritten.  TS2783

    233 |                   <PngPreview
    234 |                     currentColorPalette={this.props.currentColorPalette}
  > 235 |                     charset={this.state.charset}
        |                     ^
    236 |                     {...toFramebuf(petscii, this.state.selectedBackgroundColor, this.state.charset)}
    237 |                   />
    238 |                   {matchedBackgroundColors.length > 1 &&

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! petmate@0.8.4 build: `react-scripts build "dist-linux"`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the petmate@0.8.4 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/pi/.npm/_logs/2021-05-18T09_45_06_929Z-debug.log
manuelvio commented 3 years ago

If local assignments take precedence against spread operator moving the latter before them gets rid of compiler error. If that's the case I could make a PR (I already made one, but it landed on my fork...)