Comments (8)
@Naravyb it's definitely not a bug. html
function was not imported correctly:
new gridjs.Grid({
columns: ['Pokemon', 'URL'],
pagination: {
limit: 5,
server: {
url: (prev, page, limit) => `${prev}?limit=${limit}&offset=${page * limit}`
}
},
server: {
url: 'https://pokeapi.co/api/v2/pokemon',
then: data => data.results.map(pokemon => [
pokemon.name, gridjs.html(`<a href='${pokemon.url}'>Link to ${pokemon.name}</a>`)
]),
total: data => data.count
}
}).render(document.getElementById("wrapper"));
https://jsfiddle.net/2041953p/
from gridjs.
@Naravyb how did you import html
? Can you please create a jsFiddle/Codesandbox for me to debug?
from gridjs.
https://jsfiddle.net/nara014/ex1swno6/2/
like this problem that I found in gridJS, is this really a bug?
from gridjs.
I've found the solution by separating several components from the original grid.development.js file and this works perfectly. Powerful and nice.
https://gist.github.com/Naravyb/27c256f52d8321ec0b6d2d8cf71db179
from gridjs.
This doesn't work and I am getting the below issue
- [Grid.js] [ERROR]: Could not determine the storage type
- The above error occurred in the component: Consider adding an error boundary to your tree to customize error handling behavior.
Visit https://reactjs.org/link/error-boundaries to learn more about error boundaries.
from gridjs.
Ran into this issue with react.
Here is how I imported the html;
import { Grid, html } from 'gridjs-react';
from gridjs.
got the same issue of storage in vue with multiple instances. Did you resolved it ?
from gridjs.
For anyone trying the JSFiddle above in the future, I was able to get it to work by rewriting it using ES modules: https://jsfiddle.net/6aoqeLtw/
from gridjs.
Related Issues (20)
- Server-side search no longer calls to search function HOT 2
- Pagination doesn't reset properly when using server-side search, order & pagination and resetPageOnUpdate=true HOT 1
- Callback on text overflow to customize cell content
- Improve German translations HOT 6
- Empty translated fields fallback to default language.
- Add hint about multiple buttons to Docs/Examples/Customizing/Row buttons
- Error Cannot find module '/src/i18n/language' or its corresponding type declarations.
- Maximum call stack size exceeded error when search is enabled and columns use gridjs.html for formating HOT 3
- Sorting with Undefined Values
- Svelte example with select single row
- Fix events documentation
- Selection plugin not working after update HOT 5
- Table broken by hidden columns in a nested header
- Separate display and sort values
- Support for True Grid Layout to Enhance Data Presentation
- Does gridjs support inline edit?
- word wrapping?
- When using pagination, is there any way to know what the current index is? HOT 2
- Add examples how to hide column(s) via Events
- GridJS package on unpkg is down, cant load files or css
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gridjs.