GithubHelp home page GithubHelp logo

Comments (9)

joeschneider32 avatar joeschneider32 commented on May 28, 2024 4

I would also like the ability to use the new Twitter "X" logo if possible. Thanks! @nygardk

from react-share.

nygardk avatar nygardk commented on May 28, 2024 2

Hey, XIcon has been added in version 5.

from react-share.

rolandin avatar rolandin commented on May 28, 2024 1

You guys can just use your own Icon as children, this is using tailwindcss and my own icon is imported but this is basically the idea:

import { TwitterShareButton } from "react-share";
// import your X icon here
import { MyTwitterXIcon } from "../my-Icons-Path";

// then in your render
  <TwitterShareButton url={'https://www.google.com/'}>
    { /* this is your own Icon you can do to match your styles, now an X */ }
    <MyTwitterXIcon />
  </TwitterShareButton>

At least in "react-share": "^4.4.0", version you can, that's the one Im using

from react-share.

bn-pshulga avatar bn-pshulga commented on May 28, 2024 1

Still need to add X Icon to pack of available solutions for sharing in socials!
Thank you!

from react-share.

AndreaZero avatar AndreaZero commented on May 28, 2024

I really need this too! Tried your solution but didn't worked for me in react-share version 4.4.1

You guys can just use your own Icon as children, this is using tailwindcss and my own icon is imported but this is basically the idea:

import { TwitterShareButton } from "react-share";
// import your X icon here
import { MyTwitterXIcon } from "../my-Icons-Path";

// then in your render
  <TwitterShareButton url={'https://www.google.com/'}>
    { /* this is your own Icon you can do to match your styles, now an X */ }
    <MyTwitterXIcon />
  </TwitterShareButton>

At least in "react-share": "^4.4.0", version you can, that's the one Im using

from react-share.

ashikp avatar ashikp commented on May 28, 2024

Is there any other way to get the new logo updated? I need it Badly

from react-share.

joeschneider32 avatar joeschneider32 commented on May 28, 2024

Similar to @rolandin 's solution, here is mine:

import { TwitterShareButton } from "react-share";
import { Avatar } from "@material-ui/core";

return (
   <TwitterShareButton>
      <Avatar
         style={{
            width: size,
            height: size,
            backgroundColor: 'black',
        }}
     >
        <i
           className="fab fa-x-twitter"
           style={{ fontSize: size * 0.6 }}
        />
     </Avatar>
   </TwitterShareButton>
)

from react-share.

ashikp avatar ashikp commented on May 28, 2024

@joeschneider32 Thanks for your solution. Do i need to install fontawesome node for that?

from react-share.

bn-pshulga avatar bn-pshulga commented on May 28, 2024

Thanks a lot!

from react-share.

Related Issues (20)

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.