Giter Club home page Giter Club logo

gifted-chat-web-demo's Issues

Gifted Chat Web breaks on updating react-native-gifted-chat

Updating react-native-gifted-chat to latest version 0.16.3 breaks the build.

./node_modules/react-native-typing-animation/src/index.js
SyntaxError: /node_modules/react-native-typing-animation/src/index.js: Support for the experimental syntax 'jsx' isn't currently enabled (37:7):

  35 | 
  36 |     return (
> 37 |       <View style={[styles.container, style]}>
     |       ^
  38 |         <Dot x={dotX - dotRadius - dotMargin} y={this.state.y1} radius={dotRadius} style={dotStyles} dotColor={dotColor} />
  39 |         <Dot x={dotX} y={this.state.y2} radius={dotRadius} style={dotStyles} dotColor={dotColor} />
  40 |         <Dot x={dotX + dotRadius + dotMargin} y={this.state.y3} radius={dotRadius} style={dotStyles} dotColor={dotColor} />

Add @babel/preset-react (https://git.io/JfeDR) to the 'presets' section of your Babel config to enable transformation.
If you want to leave it as-is, add @babel/plugin-syntax-jsx (https://git.io/vb4yA) to the 'plugins' section to enable parsing.

Additional Information

  • NodeJs version: 10.16.3
  • React version: 16.13.1
  • React Native version: 0.63.1
  • react-native-gifted-chat version: 0.16.3
  • Platform(s) (iOS, Android, or both?): both

IMessage & User modules not exported

Thank you for this great chat.

After installing the web demo using npm install and previously updated the package.json as follows:

    "react-native-gifted-chat": "0.11.3",
    "react-scripts": "3.1.2",

Whe I run npm start I have the following error (same for User):

TypeScript error in gifted-chat-web-demo/src/App.tsx(2,22):
Module '"../node_modules/react-native-gifted-chat/lib"' has no exported member 'IMessage'. Did you mean 'Message'? TS2724

    1 | import React, { useState } from 'react'
  > 2 | import { GiftedChat, IMessage, User } from 'react-native-gifted-chat'
      |                      ^
    3 | import { View, Dimensions } from 'react-native'
    4 | import './App.css'

NextJS

Is this plugin compatible for NextJS? Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.