jumpingrivers / ibmsunburst Goto Github PK
View Code? Open in Web Editor NEWR ๐ฆ for the IBM โ๐ for the Personality Insights data
Home Page: https://jumpingrivers.github.io/ibmsunburst
License: Other
R ๐ฆ for the IBM โ๐ for the Personality Insights data
Home Page: https://jumpingrivers.github.io/ibmsunburst
License: Other
Moved from the README
So that we don't forget I wanted to add some documentation of the changes that I made to the source sunburst-chart. The dist
version of the library points to the d3v3
version, which also pollutes the global namespace with d3
. This means that we will likely conflict with other htmlwidgets
that use other versions of d3
.
To resolve, I made commits
d3v4
versiones5
JavaScript since it is a very outdated. Change .babelrc
to target es5
and transpile Object.assign
.dist
version which we use in htmlwidgets/lib
These steps ended up being quite straightforward and minimal but took a little longer than I expected. If we encouter again with an update of the source library, this should be quick and easy.
I left comments for some tests that I think should be added. We need to start writing tests that make sure the ibmsunburst() function works as expected.
https://github.com/lockedata/ibmsunburst/blob/master/tests/testthat/tests_basic.R
Tests in a similar package: https://github.com/timelyportfolio/sunburstR/blob/master/tests/testthat/test-basic.R
Unfortunately, the source js library does not currently provide event communication. I generally try not to fork and modify the source js, since the maintenance burden then shifts to the R package author. However, we might be able to add some code to communicate events such as click, expand, etc. to the htmlwidget binding to allow for limited integration with Shiny.
At the moment the tests check the class of the output of ibmsunburst
.
It'd be nice to add tests that check the output against a saved output like what vdiffr
does for ggplot2
objects.
Tasks:
Identify an example or examples of htmlwidget package(s) testing in the wild.
Apply the setup to this package.
Dear maintainer,
Please see the problems shown on
https://cran.r-project.org/web/checks/check_results_ibmsunburst.html.
Please correct before 2022-04-24 to safely retain your package on CRAN.
Best,
-k
The v3 API has been in use since early 2017. The ibmsunburst()
function should therefore use "v3"
as the default in the event of someone not providing a value to the version
argument.
You might notice that the fonts look a little ugly. In general, I leave fonts as default, so that a user can specify through CSS
or with a framework, such as Bootstrap, Semantic. Please let me know if you would like me to change.
IBM's example uses Bootstrap which in turn uses Helvetica Neue.
We should show people in the vignette how to do an API call to get data, what sort of things they may need in order to do so, and how to interpret the resulting chart.
Resources
Things to remember
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.