From working on plugin development, importing (I believe the correct term for this is macro) the 'forms' to quickly generate text areas, selects and etc. is incredibly useful. Adding the import now fails as '_includes' is only accessible from the control panel.
So in my template I could add this line:
{% import "_includes/forms" as forms %}
Then use something similar to this to output my forms fields?
{{ forms.textField({
label: "First Name"|t,
id: 'firstName',
name: 'firstName',
instructions: "First name (i.e John)",
placeholder: "John",
first: true,
autofocus: true,
required: true
}) }}
I know when using Symfony and Twig you can specify the namespace on where to grab the template from. Does Craft include a way to access those templates from the front end? Has anyone managed to perform this outside of the control panel?
Edit: if this is not possible, or p&t doesn't plan on making this possible (for security concerns) is there a way for a plugins template path to allow anonymous access? This way the developer could create an '_includes' and allow people to access it in the same manor?