Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Added an explanation on how to pass data to the script via data-mage-init and to access them in the script. #8311

Merged

Conversation

sathiyaaa
Copy link
Contributor

@sathiyaaa sathiyaaa commented Dec 3, 2020

Purpose of this pull request

This pull request (PR) covers #8256

Affected DevDocs pages

  • /guides/v2.4/javascript-dev-guide/javascript/requirejs.html

whatsnew
Added an explanation and example of passing parameters to JavaScript using the data-mage-init HTML attribute.

Copy link
Contributor

@BarnyShergold BarnyShergold left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice addition - just need some formatting issues sorted

Copy link
Contributor

@BarnyShergold BarnyShergold left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking a lot cleaner - a few format errors left

Also you have some linting errors - please correct - they are trailing space issues

Copy link
Contributor

@BarnyShergold BarnyShergold left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One last small suggestion! All good after that

Copy link
Contributor

@BarnyShergold BarnyShergold left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All good! Nice work.

@jeff-matthews jeff-matthews added 2.3.x Magento 2.3 related changes 2.4.x Magento 2.4.x related changes Major Update Significant original updates to existing content labels Dec 9, 2020
Copy link
Contributor

@jeff-matthews jeff-matthews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @sathiyaaa. Please address my editorial suggestions and I'll merge this.

sathiyaaa and others added 2 commits December 9, 2020 19:32
editorial changes from the code review

Co-authored-by: Jeff Matthews <[email protected]>
@jeff-matthews
Copy link
Contributor

running tests

@jeff-matthews jeff-matthews merged commit ab94a14 into magento:master Dec 9, 2020
@ghost
Copy link

ghost commented Dec 9, 2020

Hi @sathiyaaa, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
2.3.x Magento 2.3 related changes 2.4.x Magento 2.4.x related changes Major Update Significant original updates to existing content Partner: EY partners-contribution PR created by Magento partner Progress: done
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants