dominate icon indicating copy to clipboard operation
dominate copied to clipboard

small note on examples syntax

Open xkunglu opened this issue 6 years ago • 2 comments

thanks for this; its great One note, in your examples you do >>> from dominate.tags import *

but your tag names ( and I understand you got them from html ) are so short and generic that they will almost invariably collide with temporary names - e.g. img, I use everywhere in local contexts. I would suggest that you follow the example of numpy or matplotlib that in their documents define a customary shorthand for its library that generally does not collide with anything else (np, plt). Its no big deal other than I doubt anyone not using your code exclusively will not find its own shorthand; and you could probably want to own it. For your stuff I'm using dt.

xkunglu avatar Jun 16 '18 19:06 xkunglu

I totally agree

hbgodseeker avatar Sep 23 '22 08:09 hbgodseeker

import dominate.tags as dom :wink:

dekoza avatar Oct 01 '22 16:10 dekoza