Is this a requirement or a convention? If it’s a convention what’s the reason? Ctx doesn’t seem especially memorable or intuitive.
e.g.
var ctx = document.getElementById('canvas').getContext('2d');
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
It is a shorthand for the word “context”. That’s it.
Of course you can use whatever name you like – there is no real naming convention in this instance.