unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [Javascript] code for contextual behavior of < key
       [not found] <1620828980.1114868.1568416835445.ref@mail.yahoo.com>
@ 2019-09-13 23:20 ` Jorge Araya Navarro
  2019-09-14  1:41   ` Jorge Javier Araya Navarro
  0 siblings, 1 reply; 6+ messages in thread
From: Jorge Araya Navarro @ 2019-09-13 23:20 UTC (permalink / raw)
  To: emacs-devel@gnu.org

[-- Attachment #1: Type: text/plain, Size: 989 bytes --]

Hello!
As an ex-user of rjsx-mode a current user of js-mode on Emacs 27.x I missed the contextual behavior of the < key where it would insert an empty tag (</>) when attempting to write JSX code and inserting a plain < character when you don't. The code was originally written by Felipe (@felipeochoa on Github) and what I did was essentially a copy and paste with added test cases:
repository: https://gitlab.com/shackra/colibri
This thing still misses another function for expanding a balanced tag when the user deletes the / character of a self-closing tag, I don't think that code is trivial and maybe I wouldn't be able to extract it from rjsx-mode as with the extracted code.
I was wondering:
- doing this copy and pasting in regards to js-jsx-electric-lt is somewhat a violation of Felipe copyright?- is this extraction missing something?- If the author of rjsx-mode is here, would you donate parts of your code to js.el so people can have a better experience when dealing with JSX?

[-- Attachment #2: Type: text/html, Size: 1661 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Javascript] code for contextual behavior of < key
  2019-09-13 23:20 ` [Javascript] code for contextual behavior of < key Jorge Araya Navarro
@ 2019-09-14  1:41   ` Jorge Javier Araya Navarro
  2019-09-14  7:23     ` Eli Zaretskii
  0 siblings, 1 reply; 6+ messages in thread
From: Jorge Javier Araya Navarro @ 2019-09-14  1:41 UTC (permalink / raw)
  To: emacs-devel@gnu.org

[-- Attachment #1: Type: text/plain, Size: 1125 bytes --]

Sorry, let me re-format my message:

Hello!

As an ex-user of rjsx-mode a current user of js-mode on Emacs 27.x I missed the contextual
behavior of the < key where it would insert an empty tag (</>) when attempting to write JSX code and
inserting a plain < character when you don't. The code was originally written by Felipe
(@felipeochoa on Github) and what I did was essentially a copy and paste with added test cases:

repository: https://gitlab.com/shackra/colibri

This thing still misses another function for expanding a balanced tag when the user deletes the /
character of a self-closing tag, I don't think that code is trivial and maybe I wouldn't be able to
extract it from rjsx-mode as with the extracted code.

I was wondering:

- doing this copy and pasting in regards to js-jsx-electric-lt is somewhat a violation of Felipe copyright?
- is this extraction missing something?
- If the author of rjsx-mode is here, would you donate parts of your code to js.el so people can have a better experience when dealing with JSX?

Whatever comes out of this experiment would be a contribution into Emacs and js.el itself

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Javascript] code for contextual behavior of < key
  2019-09-14  1:41   ` Jorge Javier Araya Navarro
@ 2019-09-14  7:23     ` Eli Zaretskii
  2019-09-14 16:32       ` Jorge Javier Araya Navarro
  2019-09-18 21:14       ` Jorge Araya Navarro
  0 siblings, 2 replies; 6+ messages in thread
From: Eli Zaretskii @ 2019-09-14  7:23 UTC (permalink / raw)
  To: Jorge Javier Araya Navarro; +Cc: emacs-devel

> From: Jorge Javier Araya Navarro <jorgejavieran@yahoo.com.mx>
> Date: Fri, 13 Sep 2019 19:41:32 -0600
> 
> repository: https://gitlab.com/shackra/colibri
> 
> This thing still misses another function for expanding a balanced tag when the user deletes the /
> character of a self-closing tag, I don't think that code is trivial and maybe I wouldn't be able to
> extract it from rjsx-mode as with the extracted code.
> 
> I was wondering:
> 
> - doing this copy and pasting in regards to js-jsx-electric-lt is somewhat a violation of Felipe copyright?

The code is short enough to be admitted without any legal paperwork,
but the original author should explicitly agree to having his code
added to Emacs, we cannot use his code without a permission.

Thanks.



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Javascript] code for contextual behavior of < key
  2019-09-14  7:23     ` Eli Zaretskii
@ 2019-09-14 16:32       ` Jorge Javier Araya Navarro
  2019-09-18 21:14       ` Jorge Araya Navarro
  1 sibling, 0 replies; 6+ messages in thread
From: Jorge Javier Araya Navarro @ 2019-09-14 16:32 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 945 bytes --]



El sábado 14 de septiembre del 2019 a las 0123 horas, Eli Zaretskii escribió:

>> From: Jorge Javier Araya Navarro <jorgejavieran@yahoo.com.mx>
>> Date: Fri, 13 Sep 2019 19:41:32 -0600
>>
>> repository: https://gitlab.com/shackra/colibri
>>
>> This thing still misses another function for expanding a balanced tag when the user deletes the /
>> character of a self-closing tag, I don't think that code is trivial and maybe I wouldn't be able to
>> extract it from rjsx-mode as with the extracted code.
>>
>> I was wondering:
>>
>> - doing this copy and pasting in regards to js-jsx-electric-lt is somewhat a violation of Felipe copyright?
>
> The code is short enough to be admitted without any legal paperwork,
> but the original author should explicitly agree to having his code
> added to Emacs, we cannot use his code without a permission.
>
> Thanks.

Understood, Will try to reach to him and ask his permission

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Javascript] code for contextual behavior of < key
  2019-09-14  7:23     ` Eli Zaretskii
  2019-09-14 16:32       ` Jorge Javier Araya Navarro
@ 2019-09-18 21:14       ` Jorge Araya Navarro
  2019-09-20  7:28         ` Eli Zaretskii
  1 sibling, 1 reply; 6+ messages in thread
From: Jorge Araya Navarro @ 2019-09-18 21:14 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Emacs Developers

[-- Attachment #1: Type: text/plain, Size: 1403 bytes --]

 Okay, I'm back


according to Felipe, I can make use of the fragment of code (see re-using parts of rjsx-mode for js.el · Issue #118 · felipeochoa/rjsx-mode )


So, as soon has I have this together and functional will send a patch for js.el


| 
| 
| 
|  |  |

 |

 |
| 
|  | 
re-using parts of rjsx-mode for js.el · Issue #118 · felipeochoa/rjsx-mode

I'm currently using the built-in Javascript support that comes with Emacs 27.x, and I was missing the context-se...
 |

 |

 |




    El sábado, 14 de septiembre de 2019 10:33:06 GMT-6, Eli Zaretskii <eliz@gnu.org> escribió:  
 
 > From: Jorge Javier Araya Navarro <jorgejavieran@yahoo.com.mx>
> Date: Fri, 13 Sep 2019 19:41:32 -0600
> 
> repository: https://gitlab.com/shackra/colibri
> 
> This thing still misses another function for expanding a balanced tag when the user deletes the /
> character of a self-closing tag, I don't think that code is trivial and maybe I wouldn't be able to
> extract it from rjsx-mode as with the extracted code.
> 
> I was wondering:
> 
> - doing this copy and pasting in regards to js-jsx-electric-lt is somewhat a violation of Felipe copyright?

The code is short enough to be admitted without any legal paperwork,
but the original author should explicitly agree to having his code
added to Emacs, we cannot use his code without a permission.

Thanks.
  

[-- Attachment #2: Type: text/html, Size: 7736 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Javascript] code for contextual behavior of < key
  2019-09-18 21:14       ` Jorge Araya Navarro
@ 2019-09-20  7:28         ` Eli Zaretskii
  0 siblings, 0 replies; 6+ messages in thread
From: Eli Zaretskii @ 2019-09-20  7:28 UTC (permalink / raw)
  To: Jorge Araya Navarro; +Cc: emacs-devel

> Date: Wed, 18 Sep 2019 21:14:14 +0000 (UTC)
> From: Jorge Araya Navarro <jorgejavieran@yahoo.com.mx>
> Cc: Emacs Developers <emacs-devel@gnu.org>
> 
> Okay, I'm back
> 
> according to Felipe, I can make use of the fragment of code (see re-using parts of rjsx-mode for js.el · Issue
> #118 · felipeochoa/rjsx-mode )

Thanks, but we need that agreement sent By Felipe to this mailing
list, so that we could quote it in the commit log message.



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-09-20  7:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <1620828980.1114868.1568416835445.ref@mail.yahoo.com>
2019-09-13 23:20 ` [Javascript] code for contextual behavior of < key Jorge Araya Navarro
2019-09-14  1:41   ` Jorge Javier Araya Navarro
2019-09-14  7:23     ` Eli Zaretskii
2019-09-14 16:32       ` Jorge Javier Araya Navarro
2019-09-18 21:14       ` Jorge Araya Navarro
2019-09-20  7:28         ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).