Adding a path to .gitignore does not untrack files git already knows about. Use git rm --cached to drop it from the index while keeping the local copy.
echo "components.json" >> .gitignore
git rm --cached components.json
git commit -m "Stop tracking components.json"