splitting main index file