I am searching for a alternative for viewDidLayoutSubviews that is only called once.
I use this code to move the login out of the view:
override func viewDidLayoutSubviews() {
username_input.center.x -= view.bounds.width
password_input.center.x -= view.bounds.width
login_button.center.x -= view.bounds.width
}
I need to do this once, so that I can then move it in with a animation when viewDidAppear. This all worked great till I split my View into different subviews and now the function is called multiple times. I could't find any equivalent functions to this that is only called once.