[SOLVED] Copy Paste Formatted Python Code In Forum

I think it would be super useful if there was a way to copy / paste formatted python code in the forums. Perhaps there’s already a way to do this?

Is putting the code between triple back ticks not producing the result you want? Can you elaborate please?

1 Like
class Homepage(HomepageTemplate):
  def __init__(self, **properties):
    self.init_components(**properties) 

  def link_signup_click(self, **event_args):   
    d = custom_signup.Splash.Splash()
    d.signup_btn_click()

  def link_login_click(self, **event_args):
    d = custom_signup.Splash.Splash()
    d.login_btn_click()

  def link_intro_click(self, **event_args):
    alert(YouTubeVideo(youtube_id='5wb5HWVh6Fs', autoplay=True), large=True)

Hot dog! I didn’t know that existed lol, thanks!

1 Like