html
<script>
import { createIcons } from 'lucide';
import { shark } from '@lucide/lab';
createIcons({
icons: {
shark
}
});
</script>
<i data-lucide="shark"></i>
tsx
import { Icon } from 'lucide-react';
import { shark } from '@lucide/lab';
const App = () => {
return (
<Icon iconNode={shark} />
);
};
export default App;
vue
<script setup>
import { Icon } from 'lucide-vue-next';
import { shark } from '@lucide/lab';
</script>
<template>
<Icon :iconNode="shark" />
</template>
svelte
<script>
import { Icon } from 'lucide-svelte';
import { shark } from '@lucide/lab';
</script>
<Icon iconNode={shark} />
tsx
import { Icon } from 'lucide-preact';
import { shark } from '@lucide/lab';
const App = () => {
return (
<Icon iconNode={shark} />
);
};
export default App;
tsx
import { Icon } from 'lucide-solid';
import { shark } from '@lucide/lab';
const App = () => {
return (
<Icon iconNode={shark} />
);
};
export default App;
tsx
// app.module.ts
import { LucideAngularModule } from 'lucide-angular';
import { shark } from '@lucide/lab';
@NgModule({
imports: [
LucideAngularModule.pick({ Shark: shark })
],
})
// app.component.html
<lucide-icon name="Shark"></lucide-icon>
看看这个图标的实际效果
错误
功能
Shark
112
8
11