# chart label transference

**URL:** <https://talk.observablehq.com/t/chart-label-transference/2281>\
**Category:** Help\
**Created:** [August 19, 2019, 2:22pm UTC](https://talk.observablehq.com/t/chart-label-transference/2281 "2019-08-19T14:22:42Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![maliky](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/maliky/32/706_2.png) [@maliky](https://talk.observablehq.com/u/maliky)\
**Post date:** [August 19, 2019, 5:58pm UTC](https://talk.observablehq.com/t/chart-label-transference/2281/7 "2019-08-19T17:58:40Z")

</div>

I mean that when you export the [notebook as a module](https://observablehq.com/@observablehq/downloading-and-embedding-notebooks) it gives you a file ([like so)](https://api.observablehq.com/d/a1d137d57a6e939b.js?v=3) that you can open in your preferred JavaScript editor (in my case emacs) where it is usually easy to do text searches.

In the notebook module you have all the cell definition. A big and not very welcoming file at first but then with some colors and indentation, you can see that it is very repetitive and not complicated. It’s just (roughly speaking) a sequence of variable binding.  
The `xAxis_ip` cell was written as:

```javascript
    main.variable(observer("xAxis_ip")).define("xAxis_ip", ["height","margin","d3","x_ir"], function(height,margin,d3,x_ir){return(
	g => g
	    .attr("transform", `translate(0,${height - margin.bottom})`)
	    .call(d3.axisBottom(x_ir)
		    .tickSizeOuter(0))
    )});

```

while the `xAxis_ir`

```javascript
    main.variable(observer("xAxis_ir")).define("xAxis_ir", ["height","margin","d3","x_ir"], function(height,margin,d3,x_ir){return(
	g => g
	    .attr("transform", `translate(0,${height - margin.bottom})`)
	    .call(d3.axisBottom(x_ir)
		    .tickSizeOuter(0))
    )});

```

Very similar to what you have in the notebook but, if your editor can highlight identical variables then the repetition of `x_ir` jumps to the eye. That’s what I mean.

Also, I’m really not a big fan of coding in the navigator and I very happy to have understood this module stuff (check my [previous post](https://talk.observablehq.com/t/observable-runtime-inspector-and-tachyonss-atomic-powers/2278/2)) today 🙂

---

_[View the full topic](https://talk.observablehq.com/t/chart-label-transference/2281)._
