\documentclass{book}
\usepackage{subfiles}
\usepackage{import}

\input{./chapters/preamble}
\import{chapters}{imported.tex}

\title{Test file.}
\author{Tester Testington}

\begin{document}
\maketitle

\chapter{Chapter in main}
\subfile{chapters/subfile.tex}

\begin{quote}
  A custom environment.
\end{quote}

\input{./chapters/chapter}

\input{./chapters/equations}
\end{document}
