<script>
import Grid from "gridjs-svelte";
const data = [
{ name: "John", email: "john@example.com" },
{ name: "Mark", email: "mark@gmail.com" },
];
// https://gridjs.io/docs/config/style
const style = {
table: {
border: '3px solid #ccc'
},
th: {
'background-color': 'rgba(0, 0, 0, 0.1)',
color: '#000',
'border-bottom': '3px solid #ccc',
'text-align': 'center'
},
td: {
'text-align': 'center'
}
}
// https://gridjs.io/docs/config/className
const className = {
tbody: 'table-body'
}
</script>
<Grid {data} {style} {className} />
<style global>
@import "https://cdn.jsdelivr.net/npm/gridjs/dist/theme/mermaid.min.css";
:global(.table-body > tr:nth-child(even)) {