Replies: 2 comments
-
is it possibile? |
Beta Was this translation helpful? Give feedback.
0 replies
-
More general question: is it possible to access data from another data file? _data/first.js
_data/second.js // first.js
export default function () {
return { foo: 'bar' };
} // second.js
```js
// first.js
export default function () {
// data ?
// this.data ?
return { baz: data.first.foo + ' baz' };
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
in src/data I have two files:
inside eleventyComputed I have:
`module.exports = {
"data1": "foo",
"data2": (data) => {
};`
Ok, Can I access data2 in commonData.js? How? If I get eleventyComputed.data1 all it's ok and return data (static) but I I try data2 it return the function instead the result
thank you
Beta Was this translation helpful? Give feedback.
All reactions