function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Ranjith DevRanjith Dev 

security issues

Hi Team,

I have a lightning Component that used the access="global". Salesforce has suggested please remove the access="global" in all lightning components.
User-added image
but when I remove the access="global", the package got not Upload it showing an error message.
User-added image
any suggestion that would be helpful for me.

Thank you.
Ranjith M
Best Answer chosen by Ranjith Dev
SwethaSwetha (Salesforce Developers) 
HI Ranjith,
The error is probably related to the scenario explained in https://salesforce.stackexchange.com/questions/307758/component-is-from-a-managed-package-and-must-be-marked-access-global-on-sfd

If you are releasing a component as part of a package, then you definitely want your component to be accessible outside of your org, for which you would need to mark it with a global access.

See related: https://salesforce.stackexchange.com/questions/219001/lightning-component-in-this-managed-package-must-be-marked-access-global
https://salesforce.stackexchange.com/questions/176948/when-to-set-lightning-access-global-in-managed-packages

If this information helps, please mark the answer as best.Thank you

All Answers

SwethaSwetha (Salesforce Developers) 
HI Ranjith,
The error is probably related to the scenario explained in https://salesforce.stackexchange.com/questions/307758/component-is-from-a-managed-package-and-must-be-marked-access-global-on-sfd

If you are releasing a component as part of a package, then you definitely want your component to be accessible outside of your org, for which you would need to mark it with a global access.

See related: https://salesforce.stackexchange.com/questions/219001/lightning-component-in-this-managed-package-must-be-marked-access-global
https://salesforce.stackexchange.com/questions/176948/when-to-set-lightning-access-global-in-managed-packages

If this information helps, please mark the answer as best.Thank you
This was selected as the best answer
Ranjith DevRanjith Dev
Got the information. Thank you @Swetha.