Skip to content

Commit

Permalink
feat: render profile badges fully through react components by default
Browse files Browse the repository at this point in the history
  • Loading branch information
Ziping Liu committed May 12, 2024
1 parent b0b5577 commit dfa7ab6
Show file tree
Hide file tree
Showing 6 changed files with 13,020 additions and 78 deletions.
47 changes: 21 additions & 26 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 8 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-linkedinbadge",
"version": "5.12.2024",
"version": "5.12.2025",
"description": "The LinkedIn Badge Rendering React Component is a powerful tool for displaying LinkedIn badges on websites. With customizable options and support for both profile and entity badges, this component offers improved features over LinkedIn's basic implementation. It enhances code organization by separating badge container rendering from dynamic content rendering and efficiently handles asynchronous loading of content from LinkedIn servers. This component also allows for easy management of multiple badges on a page and provides a callback function for tracking badge rendering completion. Make sure to review the licensing information for proper usage.",
"repository": {
"type": "git",
Expand Down Expand Up @@ -76,6 +76,7 @@
],
"files": [
"lib",
"src/LinkedInBadge.css",
"LICENSE.md",
"types",
"README.md",
Expand Down Expand Up @@ -141,16 +142,19 @@
"jsdelivr": "./lib/linkedinbadge.js",
"exports": {
".": {
"types": "./lib/bundle.esm.d.ts",
"types": "./lib/index.d.ts",
"import": "./lib/linkedinbadge.esm.js",
"require": "./lib/linkedinbadge.cjs.js",
"node": "./lib/linkedinbadge.cjs.js",
"default": "./lib/linkedinbadge.esm.js",
"umd": "./lib/linkedinbadge.bundle.js"
}
},
"types": "./lib/bundle.esm.d.ts",
"types": "./lib/index.d.ts",
"umd:main": "./lib/linkedinbadge.bundle.js",
"main": "./lib/linkedinbadge.cjs.js",
"module": "./lib/linkedinbadge.esm.js"
"module": "./lib/linkedinbadge.esm.js",
"dependencies": {
"rollup-plugin-import-css": "^3.5.0"
}
}
10 changes: 4 additions & 6 deletions rollup.config.all.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import replace from "@rollup/plugin-replace";
import typescript from "rollup-plugin-typescript2";
import terser from "@rollup/plugin-terser";
import { dts } from "rollup-plugin-dts";
import css from 'rollup-plugin-import-css';
import packageJson from "./package.json";
const outputCommonConf = {
sourcemap: "inline",
Expand Down Expand Up @@ -56,7 +57,8 @@ export default [
"process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV),
preventAssignment: true,
}),


css(),
resolve(),
commonjs(),
typescript({
Expand All @@ -79,9 +81,5 @@ export default [
],
external: ["react", "react-dom", "styled-components"],
},
{
input: "types/index.d.ts",
output: [{ file: "lib/bundle.esm.d.ts", format: "esm" }],
plugins: [dts()],
},

];
2 changes: 2 additions & 0 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import peerDepsExternal from "rollup-plugin-peer-deps-external";
import resolve from "@rollup/plugin-node-resolve";
import replace from "@rollup/plugin-replace";
import typescript from "rollup-plugin-typescript2";
import css from "rollup-plugin-import-css";
import terser from "@rollup/plugin-terser";

const config = {
Expand All @@ -20,6 +21,7 @@ const config = {
},
],
plugins: [
css(),
typescript({
useTsconfigDeclarationDir: true,
sourceMap: true,
Expand Down
Loading

0 comments on commit dfa7ab6

Please sign in to comment.