Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
d3-marcon
Advanced tools
Readme
Margin conventions for d3-selection.
If you use NPM, npm install d3-marcon
. Otherwise, download the latest release.
You can also load directly from unpkg. You may use the entire D3.js library or, at a minimum, d3-selection.
<script src="https://d3js.org/d3-selection.v1.min.js"></script>
<script src="https://unpkg.com/d3-marcon/build/d3-marcon.min.js"></script>
<script>
var m = d3.marcon()
.top(10)
.bottom(10)
.left(10)
.right(10);
m.render();
m.svg().append("rect")
.attr("width", m.innerWidth())
.attr("height", m.innerHeight())
.style("fill", "steelblue");
</script>
A live example on bl.ocks.org.
Constructs a visualization generator, or viz, on which you can set and get the dimensions and margins, and append an svg
element with a nested g
to a DOM element.
Selects a DOM element to append the viz to. Defaults to "body"
.
Sets or gets the viz's top margin. Defaults to 0
.
Sets or gets the viz's right margin. Defaults to 0
.
Sets or gets the viz's bottom margin. Defaults to 0
.
Sets or gets the viz's left margin. Defaults to 0
.
Sets or gets the viz's width. Defaults to 900
.
Sets or gets the viz's height. Defaults to 600
.
Gets the viz's innerWidth, which is equal to width - left - right
.
Gets the viz's innerHeight, which is equal to height - top - bottom
.
Renders the viz to the DOM.
Gets the svg
element that contains the viz. Returns undefined
if the viz has not yet been rendered.
FAQs
Margin conventions for d3-selection.
The npm package d3-marcon receives a total of 88 weekly downloads. As such, d3-marcon popularity was classified as not popular.
We found that d3-marcon demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.