Skip to content

Is it possible to create a variable number of placeholders? #220

@diego-rapoport

Description

@diego-rapoport

When you create an init in a python class, you have a variable number or variables that you define.
Something like:

class Person:
   def __init__(self, arg1, arg2 ...):
       ...

And for each one you usually have:

self.arg1 = arg1
self.arg2 = arg2

Can I make a snippet in a way that for each arg I increase it generates a new self.argx = x?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions