What's the `._xxx` file in macOS? I created a index.php file under my phplessons directory:



before I used the phpStorm to open the directory, Apple's Text Editor opened it, now I have phpStorm open, but there is a ._index.php file alongside index.php file.

I don't know what's the ._index.php file is, but in it I find a string com.apple.TextEncoding.

What is this file and what is its purpose?
It's simply a temporary metadata file created by TextEdit app. You can safely ignore it.

File beginning with . are hidden files in macOS. Files beginning with ._ are metadata files created by apps in macOS.

If you do not wish to be bothered by such files, it's better to add it in your version control ignore rules (if you use one).