There's a note on the aws_s3_bucket_object page saying it's deprecated and to use aws_s3_bucket instead:
The aws_s3_bucket_object resource is DEPRECATED and will be removed in a future version! Use aws_s3_object instead, where new features and fixes will be added. When replacing aws_s3_bucket_object with aws_s3_object in your configuration, on the next apply, Terraform will recreate the object. If you prefer to not have Terraform recreate the object, import the object using aws_s3_object.
When I go over to the aws_s3_bucket page, there's no example of how to upload a file, only how to create a bucket. A number of articles online also point to use aws_s3_bucket to create the bucket but still use aws_s3_bucket_object to upload files, is this still the correct practice?