AndrewRadev / sideways.vim

A Vim plugin to move function arguments (and other delimited-by-something items) left and right.
http://www.vim.org/scripts/script.php?script_id=4171
MIT License
481 stars 9 forks source link

React #30

Closed roberbnd closed 6 years ago

roberbnd commented 6 years ago

Is possible configure the plugin to work with react, I have this, but doesn't work in the attributes of the tags

import React from 'react';
import uid from 'uid';

const CourseAddForm = (props) => (
  <form onSubmit={props.onAddCourse}>
    <input type="text" placeholder="Nombre del curso" name="name"/>
    <input type="text" placeholder="Profesor" name="teacher"/>
    <input type="hidden" name="id" value={Math.floor( Math.random() * 100 )}/>
    <input type="submit" value="Guardar"/>
  </form>
);

export default CourseAddForm;
roberbnd commented 6 years ago

I found my filetype was "javascript" not "javascript.jsx" thanks it's working !

AndrewRadev commented 6 years ago

Excellent, glad it worked out :).